Last active
July 2, 2020 01:09
-
-
Save airtonGit/0851acd53c75b134ef2b430f1bed5420 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Exemplo em GO | |
type IMsgBasica interface{ | |
SetTexto(valor string) | |
} | |
// Exemplo de objeto | |
type MsgOla struct{ | |
(…) | |
} | |
// Ao definir este método MsgOla "se parece" com IMsgBasica | |
// logo implementa a interface e poderá ser utilizada | |
func (t *MsgOla) SetTexto(valor string){ | |
(…) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment