GraphQL API and utilities for the rpdata project
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

17 lines
515 B

  1. package models
  2. // A Tag associates a story with other content, like other stories, logs and more.
  3. type Tag struct {
  4. Kind TagKind `bson:"kind"`
  5. Name string `bson:"name"`
  6. }
  7. // Equal returns true if the tags match one another.
  8. func (tag *Tag) Equal(other Tag) bool {
  9. return tag.Kind == other.Kind && tag.Name == other.Name
  10. }
  11. // IsChangeObject is an interface implementation to identify it as a valid
  12. // ChangeObject in GQL.
  13. func (*Tag) IsChangeObject() {
  14. panic("this method is a dummy, and so is its caller")
  15. }