Documentation ¶
Overview ¶
Package propertycontent contains the implementation for the content property. All applications are strongly encouraged to use the interface instead of this concrete definition. The interfaces allow applications to consume only the types and properties needed and be independent of the go-fed implementation if another alternative implementation is created. This package is code-generated and subject to the same license as the go-fed tool used to generate it.
This package is independent of other types' and properties' implementations by having a Manager injected into it to act as a factory for the concrete implementations. The implementations have been generated into their own separate subpackages for each vocabulary.
Strongly consider using the interfaces instead of this package.
Index ¶
- func DeserializeContentProperty(m map[string]interface{}, aliasMap map[string]string) (vocab.ActivityStreamsContentProperty, error)
- func SetManager(m privateManager)
- type ActivityStreamsContentProperty
- func (this *ActivityStreamsContentProperty) AppendIRI(v *url.URL)
- func (this *ActivityStreamsContentProperty) AppendRDFLangString(v map[string]string)
- func (this *ActivityStreamsContentProperty) AppendXMLSchemaString(v string)
- func (this ActivityStreamsContentProperty) At(index int) vocab.ActivityStreamsContentPropertyIterator
- func (this ActivityStreamsContentProperty) Begin() vocab.ActivityStreamsContentPropertyIterator
- func (this ActivityStreamsContentProperty) Empty() bool
- func (this ActivityStreamsContentProperty) End() vocab.ActivityStreamsContentPropertyIterator
- func (this *ActivityStreamsContentProperty) InsertIRI(idx int, v *url.URL)
- func (this *ActivityStreamsContentProperty) InsertRDFLangString(idx int, v map[string]string)
- func (this *ActivityStreamsContentProperty) InsertXMLSchemaString(idx int, v string)
- func (this ActivityStreamsContentProperty) JSONLDContext() map[string]string
- func (this ActivityStreamsContentProperty) KindIndex(idx int) int
- func (this ActivityStreamsContentProperty) Len() (length int)
- func (this ActivityStreamsContentProperty) Less(i, j int) bool
- func (this ActivityStreamsContentProperty) LessThan(o vocab.ActivityStreamsContentProperty) bool
- func (this ActivityStreamsContentProperty) Name() string
- func (this *ActivityStreamsContentProperty) PrependIRI(v *url.URL)
- func (this *ActivityStreamsContentProperty) PrependRDFLangString(v map[string]string)
- func (this *ActivityStreamsContentProperty) PrependXMLSchemaString(v string)
- func (this *ActivityStreamsContentProperty) Remove(idx int)
- func (this ActivityStreamsContentProperty) Serialize() (interface{}, error)
- func (this *ActivityStreamsContentProperty) SetIRI(idx int, v *url.URL)
- func (this *ActivityStreamsContentProperty) SetRDFLangString(idx int, v map[string]string)
- func (this *ActivityStreamsContentProperty) SetXMLSchemaString(idx int, v string)
- func (this ActivityStreamsContentProperty) Swap(i, j int)
- type ActivityStreamsContentPropertyIterator
- func (this ActivityStreamsContentPropertyIterator) GetIRI() *url.URL
- func (this ActivityStreamsContentPropertyIterator) GetLanguage(bcp47 string) string
- func (this ActivityStreamsContentPropertyIterator) GetRDFLangString() map[string]string
- func (this ActivityStreamsContentPropertyIterator) GetXMLSchemaString() string
- func (this ActivityStreamsContentPropertyIterator) HasAny() bool
- func (this ActivityStreamsContentPropertyIterator) HasLanguage(bcp47 string) bool
- func (this ActivityStreamsContentPropertyIterator) IsIRI() bool
- func (this ActivityStreamsContentPropertyIterator) IsRDFLangString() bool
- func (this ActivityStreamsContentPropertyIterator) IsXMLSchemaString() bool
- func (this ActivityStreamsContentPropertyIterator) JSONLDContext() map[string]string
- func (this ActivityStreamsContentPropertyIterator) KindIndex() int
- func (this ActivityStreamsContentPropertyIterator) LessThan(o vocab.ActivityStreamsContentPropertyIterator) bool
- func (this ActivityStreamsContentPropertyIterator) Name() string
- func (this ActivityStreamsContentPropertyIterator) Next() vocab.ActivityStreamsContentPropertyIterator
- func (this ActivityStreamsContentPropertyIterator) Prev() vocab.ActivityStreamsContentPropertyIterator
- func (this *ActivityStreamsContentPropertyIterator) SetIRI(v *url.URL)
- func (this *ActivityStreamsContentPropertyIterator) SetLanguage(bcp47, value string)
- func (this *ActivityStreamsContentPropertyIterator) SetRDFLangString(v map[string]string)
- func (this *ActivityStreamsContentPropertyIterator) SetXMLSchemaString(v string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DeserializeContentProperty ¶
func DeserializeContentProperty(m map[string]interface{}, aliasMap map[string]string) (vocab.ActivityStreamsContentProperty, error)
DeserializeContentProperty creates a "content" property from an interface representation that has been unmarshalled from a text or binary format.
func SetManager ¶
func SetManager(m privateManager)
SetManager sets the manager package-global variable. For internal use only, do not use as part of Application behavior. Must be called at golang init time.
Types ¶
type ActivityStreamsContentProperty ¶
type ActivityStreamsContentProperty struct {
// contains filtered or unexported fields
}
ActivityStreamsContentProperty is the non-functional property "content". It is permitted to have one or more values, and of different value types.
func NewActivityStreamsContentProperty ¶
func NewActivityStreamsContentProperty() *ActivityStreamsContentProperty
NewActivityStreamsContentProperty creates a new content property.
func (*ActivityStreamsContentProperty) AppendIRI ¶
func (this *ActivityStreamsContentProperty) AppendIRI(v *url.URL)
AppendIRI appends an IRI value to the back of a list of the property "content"
func (*ActivityStreamsContentProperty) AppendRDFLangString ¶
func (this *ActivityStreamsContentProperty) AppendRDFLangString(v map[string]string)
AppendRDFLangString appends a langString value to the back of a list of the property "content". Invalidates iterators that are traversing using Prev.
func (*ActivityStreamsContentProperty) AppendXMLSchemaString ¶
func (this *ActivityStreamsContentProperty) AppendXMLSchemaString(v string)
AppendXMLSchemaString appends a string value to the back of a list of the property "content". Invalidates iterators that are traversing using Prev.
func (ActivityStreamsContentProperty) At ¶
func (this ActivityStreamsContentProperty) At(index int) vocab.ActivityStreamsContentPropertyIterator
At returns the property value for the specified index. Panics if the index is out of bounds.
func (ActivityStreamsContentProperty) Begin ¶
func (this ActivityStreamsContentProperty) Begin() vocab.ActivityStreamsContentPropertyIterator
Begin returns the first iterator, or nil if empty. Can be used with the iterator's Next method and this property's End method to iterate from front to back through all values.
func (ActivityStreamsContentProperty) Empty ¶
func (this ActivityStreamsContentProperty) Empty() bool
Empty returns returns true if there are no elements.
func (ActivityStreamsContentProperty) End ¶
func (this ActivityStreamsContentProperty) End() vocab.ActivityStreamsContentPropertyIterator
End returns beyond-the-last iterator, which is nil. Can be used with the iterator's Next method and this property's Begin method to iterate from front to back through all values.
func (*ActivityStreamsContentProperty) InsertIRI ¶
func (this *ActivityStreamsContentProperty) InsertIRI(idx int, v *url.URL)
Insert inserts an IRI value at the specified index for a property "content". Existing elements at that index and higher are shifted back once. Invalidates all iterators.
func (*ActivityStreamsContentProperty) InsertRDFLangString ¶
func (this *ActivityStreamsContentProperty) InsertRDFLangString(idx int, v map[string]string)
InsertRDFLangString inserts a langString value at the specified index for a property "content". Existing elements at that index and higher are shifted back once. Invalidates all iterators.
func (*ActivityStreamsContentProperty) InsertXMLSchemaString ¶
func (this *ActivityStreamsContentProperty) InsertXMLSchemaString(idx int, v string)
InsertXMLSchemaString inserts a string value at the specified index for a property "content". Existing elements at that index and higher are shifted back once. Invalidates all iterators.
func (ActivityStreamsContentProperty) JSONLDContext ¶
func (this ActivityStreamsContentProperty) JSONLDContext() map[string]string
JSONLDContext returns the JSONLD URIs required in the context string for this property and the specific values that are set. The value in the map is the alias used to import the property's value or values.
func (ActivityStreamsContentProperty) KindIndex ¶
func (this ActivityStreamsContentProperty) KindIndex(idx int) int
KindIndex computes an arbitrary value for indexing this kind of value. This is a leaky API method specifically needed only for alternate implementations for go-fed. Applications should not use this method. Panics if the index is out of bounds.
func (ActivityStreamsContentProperty) Len ¶
func (this ActivityStreamsContentProperty) Len() (length int)
Len returns the number of values that exist for the "content" property.
func (ActivityStreamsContentProperty) Less ¶
func (this ActivityStreamsContentProperty) Less(i, j int) bool
Less computes whether another property is less than this one. Mixing types results in a consistent but arbitrary ordering
func (ActivityStreamsContentProperty) LessThan ¶
func (this ActivityStreamsContentProperty) LessThan(o vocab.ActivityStreamsContentProperty) bool
LessThan compares two instances of this property with an arbitrary but stable comparison. Applications should not use this because it is only meant to help alternative implementations to go-fed to be able to normalize nonfunctional properties.
func (ActivityStreamsContentProperty) Name ¶
func (this ActivityStreamsContentProperty) Name() string
Name returns the name of this property ("content") with any alias.
func (*ActivityStreamsContentProperty) PrependIRI ¶
func (this *ActivityStreamsContentProperty) PrependIRI(v *url.URL)
PrependIRI prepends an IRI value to the front of a list of the property "content".
func (*ActivityStreamsContentProperty) PrependRDFLangString ¶
func (this *ActivityStreamsContentProperty) PrependRDFLangString(v map[string]string)
PrependRDFLangString prepends a langString value to the front of a list of the property "content". Invalidates all iterators.
func (*ActivityStreamsContentProperty) PrependXMLSchemaString ¶
func (this *ActivityStreamsContentProperty) PrependXMLSchemaString(v string)
PrependXMLSchemaString prepends a string value to the front of a list of the property "content". Invalidates all iterators.
func (*ActivityStreamsContentProperty) Remove ¶
func (this *ActivityStreamsContentProperty) Remove(idx int)
Remove deletes an element at the specified index from a list of the property "content", regardless of its type. Panics if the index is out of bounds. Invalidates all iterators.
func (ActivityStreamsContentProperty) Serialize ¶
func (this ActivityStreamsContentProperty) Serialize() (interface{}, error)
Serialize converts this into an interface representation suitable for marshalling into a text or binary format. Applications should not need this function as most typical use cases serialize types instead of individual properties. It is exposed for alternatives to go-fed implementations to use.
func (*ActivityStreamsContentProperty) SetIRI ¶
func (this *ActivityStreamsContentProperty) SetIRI(idx int, v *url.URL)
SetIRI sets an IRI value to be at the specified index for the property "content". Panics if the index is out of bounds.
func (*ActivityStreamsContentProperty) SetRDFLangString ¶
func (this *ActivityStreamsContentProperty) SetRDFLangString(idx int, v map[string]string)
SetRDFLangString sets a langString value to be at the specified index for the property "content". Panics if the index is out of bounds. Invalidates all iterators.
func (*ActivityStreamsContentProperty) SetXMLSchemaString ¶
func (this *ActivityStreamsContentProperty) SetXMLSchemaString(idx int, v string)
SetXMLSchemaString sets a string value to be at the specified index for the property "content". Panics if the index is out of bounds. Invalidates all iterators.
func (ActivityStreamsContentProperty) Swap ¶
func (this ActivityStreamsContentProperty) Swap(i, j int)
Swap swaps the location of values at two indices for the "content" property.
type ActivityStreamsContentPropertyIterator ¶
type ActivityStreamsContentPropertyIterator struct {
// contains filtered or unexported fields
}
ActivityStreamsContentPropertyIterator is an iterator for a property. It is permitted to be one of multiple value types. At most, one type of value can be present, or none at all. Setting a value will clear the other types of values so that only one of the 'Is' methods will return true. It is possible to clear all values, so that this property is empty.
func NewActivityStreamsContentPropertyIterator ¶
func NewActivityStreamsContentPropertyIterator() *ActivityStreamsContentPropertyIterator
NewActivityStreamsContentPropertyIterator creates a new ActivityStreamsContent property.
func (ActivityStreamsContentPropertyIterator) GetIRI ¶
func (this ActivityStreamsContentPropertyIterator) GetIRI() *url.URL
GetIRI returns the IRI of this property. When IsIRI returns false, GetIRI will return an arbitrary value.
func (ActivityStreamsContentPropertyIterator) GetLanguage ¶
func (this ActivityStreamsContentPropertyIterator) GetLanguage(bcp47 string) string
GetLanguage returns the value for the specified BCP47 language code, or an empty string if it is either not a language map or no value is present.
func (ActivityStreamsContentPropertyIterator) GetRDFLangString ¶
func (this ActivityStreamsContentPropertyIterator) GetRDFLangString() map[string]string
GetRDFLangString returns the value of this property. When IsRDFLangString returns false, GetRDFLangString will return an arbitrary value.
func (ActivityStreamsContentPropertyIterator) GetXMLSchemaString ¶
func (this ActivityStreamsContentPropertyIterator) GetXMLSchemaString() string
GetXMLSchemaString returns the value of this property. When IsXMLSchemaString returns false, GetXMLSchemaString will return an arbitrary value.
func (ActivityStreamsContentPropertyIterator) HasAny ¶
func (this ActivityStreamsContentPropertyIterator) HasAny() bool
HasAny returns true if any of the values are set, except for the natural language map. When true, the specific has, getter, and setter methods may be used to determine what kind of value there is to access and set this property. To determine if the property was set as a natural language map, use the IsRDFLangString method instead.
func (ActivityStreamsContentPropertyIterator) HasLanguage ¶
func (this ActivityStreamsContentPropertyIterator) HasLanguage(bcp47 string) bool
HasLanguage returns true if the natural language map has an entry for the specified BCP47 language code.
func (ActivityStreamsContentPropertyIterator) IsIRI ¶
func (this ActivityStreamsContentPropertyIterator) IsIRI() bool
IsIRI returns true if this property is an IRI. When true, use GetIRI and SetIRI to access and set this property
func (ActivityStreamsContentPropertyIterator) IsRDFLangString ¶
func (this ActivityStreamsContentPropertyIterator) IsRDFLangString() bool
IsRDFLangString returns true if this property has a type of "langString". When true, use the GetRDFLangString and SetRDFLangString methods to access and set this property.. To determine if the property was set as a natural language map, use the IsRDFLangString method instead.
func (ActivityStreamsContentPropertyIterator) IsXMLSchemaString ¶
func (this ActivityStreamsContentPropertyIterator) IsXMLSchemaString() bool
IsXMLSchemaString returns true if this property has a type of "string". When true, use the GetXMLSchemaString and SetXMLSchemaString methods to access and set this property.. To determine if the property was set as a natural language map, use the IsRDFLangString method instead.
func (ActivityStreamsContentPropertyIterator) JSONLDContext ¶
func (this ActivityStreamsContentPropertyIterator) JSONLDContext() map[string]string
JSONLDContext returns the JSONLD URIs required in the context string for this property and the specific values that are set. The value in the map is the alias used to import the property's value or values.
func (ActivityStreamsContentPropertyIterator) KindIndex ¶
func (this ActivityStreamsContentPropertyIterator) KindIndex() int
KindIndex computes an arbitrary value for indexing this kind of value. This is a leaky API detail only for folks looking to replace the go-fed implementation. Applications should not use this method.
func (ActivityStreamsContentPropertyIterator) LessThan ¶
func (this ActivityStreamsContentPropertyIterator) LessThan(o vocab.ActivityStreamsContentPropertyIterator) bool
LessThan compares two instances of this property with an arbitrary but stable comparison. Applications should not use this because it is only meant to help alternative implementations to go-fed to be able to normalize nonfunctional properties.
func (ActivityStreamsContentPropertyIterator) Name ¶
func (this ActivityStreamsContentPropertyIterator) Name() string
Name returns the name of this property: "ActivityStreamsContent".
func (ActivityStreamsContentPropertyIterator) Next ¶
func (this ActivityStreamsContentPropertyIterator) Next() vocab.ActivityStreamsContentPropertyIterator
Next returns the next iterator, or nil if there is no next iterator.
func (ActivityStreamsContentPropertyIterator) Prev ¶
func (this ActivityStreamsContentPropertyIterator) Prev() vocab.ActivityStreamsContentPropertyIterator
Prev returns the previous iterator, or nil if there is no previous iterator.
func (*ActivityStreamsContentPropertyIterator) SetIRI ¶
func (this *ActivityStreamsContentPropertyIterator) SetIRI(v *url.URL)
SetIRI sets the value of this property. Calling IsIRI afterwards returns true.
func (*ActivityStreamsContentPropertyIterator) SetLanguage ¶
func (this *ActivityStreamsContentPropertyIterator) SetLanguage(bcp47, value string)
SetLanguage sets the value for the specified BCP47 language code.
func (*ActivityStreamsContentPropertyIterator) SetRDFLangString ¶
func (this *ActivityStreamsContentPropertyIterator) SetRDFLangString(v map[string]string)
SetRDFLangString sets the value of this property and clears the natural language map. Calling IsRDFLangString afterwards will return true. Calling IsRDFLangString afterwards returns false.
func (*ActivityStreamsContentPropertyIterator) SetXMLSchemaString ¶
func (this *ActivityStreamsContentPropertyIterator) SetXMLSchemaString(v string)
SetXMLSchemaString sets the value of this property and clears the natural language map. Calling IsXMLSchemaString afterwards will return true. Calling IsRDFLangString afterwards returns false.