Mourners at St James' Church in Charlestown and across the country were told Detective Garda Colm Horkan epitomised what all members of An Garda Síochána should strive to be.
Garda Commissioner Drew Harris told the funeral Mass that Garda Horkan was approachable and well known and respected.
"He was approachable and well known and respected in his local community and also in Castlerea where he was extremely well regarded, well liked and where he policed for 21 years of his 26 years of service."
The Garda Commissioner said he felt immense sadness but also privileged to be asked to speak at the State Funeral of the Detective Garda.
Commissioner Harris told mourners that Det Gda Horkan's police service was characterised by hard work.
"In the end at 12 midnight on Wednesday evening his service is entirely characterised by his determination and courage in the exercise of his duty to protect society."
The Commissioner said An Garda Síochána had been 'overwhelmed' by the support of communities in Mayo, Roscommon and throughout Ireland.
"The outpouring of condolence and support in response to Colm's death and also in response to the shocking manner of his death has supported all of us who work in An Garda Síochána.
He said the manner of Colm's death should not eclipse his life.
"Colm belonged first to his family," said Commissioner Harris who then extended his sincere condolences to the Horkan family.
He noted Colm's involvement in the community and his great interest in sport.
"I know he took great interest in all sport, but took particular interest in GAA where he excelled. He was also a committed and active club member.
Colm also belonged to the wider family of An Garda Síochána and his death has been a heavy blow to us all."
He went on to assure the Horkan family that they would have the full support of the force over the months and years ahead.
"Colm's name will live on and he will be remembered within An Garda Síochána in the years ahead. Today we grieve beside his coffin, but this is only the beginning of our remembrance of Det Gda Colm Horkan."
"I trust that those who continue to serve can honour Colm's legacy in the manner we conduct our duties, in the manner we protect and serve society and as Colm did and step forward at a crucial moment."