Advertisement
cwchen

[Go] Interface embedding

Oct 7th, 2017
738
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Go 0.15 KB | None | 0 0
  1. type IPoint interface {
  2.     X() float64
  3.     Y() float64
  4.     SetX(float64)
  5.     SetY(float64)
  6. }
  7.  
  8. type IPoint3D interface {
  9.     IPoint
  10.     Z() float64
  11.     SetZ(float64)
  12. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement