func (this *ActivityStreamsUrlPropertyIterator) SetXMLSchemaAnyURI(v *url.URL) {
	this.clear()
	this.xmlschemaAnyURIMember = v
}
SetXMLSchemaAnyURI sets the value of this property. Calling IsXMLSchemaAnyURI
afterwards returns true.
package propertyurl
import (
	"fmt"
	anyuri "github.com/go-fed/activity/streams/values/anyURI"
	vocab "github.com/go-fed/activity/streams/vocab"
	"net/url"
)
type ActivityStreamsUrlPropertyIterator struct {
	xmlschemaAnyURIMember        *url.URL
	activitystreamsLinkMember    vocab.ActivityStreamsLink
	activitystreamsMentionMember vocab.ActivityStreamsMention
	unknown                      interface{}
	alias                        string
	myIdx                        int
	parent                       vocab.ActivityStreamsUrlProperty
}
func NewActivityStreamsUrlPropertyIterator() *ActivityStreamsUrlPropertyIterator {
	return &ActivityStreamsUrlPropertyIterator{alias: ""}
}
func deserializeActivityStreamsUrlPropertyIterator(i interface{}, aliasMap map[string]string) (*ActivityStreamsUrlPropertyIterator, error) {
	alias := ""
	if a, ok := aliasMap["https://www.w3.org/ns/activitystreams"]; ok {
		alias = a
	}
	if m, ok := i.(map[string]interface{}); ok {
		if v, err := mgr.DeserializeLinkActivityStreams()(m, aliasMap); err == nil {
			this := &ActivityStreamsUrlPropertyIterator{
				activitystreamsLinkMember: v,
				alias:                     alias,
			}
			return this, nil
		} else if v, err := mgr.DeserializeMentionActivityStreams()(m, aliasMap); err == nil {
			this := &ActivityStreamsUrlPropertyIterator{
				activitystreamsMentionMember: v,
				alias:                        alias,
			}
			return this, nil
		}
	}
	if v, err := anyuri.DeserializeAnyURI(i); err == nil {
		this := &ActivityStreamsUrlPropertyIterator{
			alias:                 alias,
			xmlschemaAnyURIMember: v,
		}
		return this, nil
	}
	this := &ActivityStreamsUrlPropertyIterator{
		alias:   alias,
		unknown: i,
	}
	return this, nil
}
func (this ActivityStreamsUrlPropertyIterator) GetActivityStreamsLink() vocab.ActivityStreamsLink {
	return this.activitystreamsLinkMember
}
func (this ActivityStreamsUrlPropertyIterator) GetActivityStreamsMention() vocab.ActivityStreamsMention {
	return this.activitystreamsMentionMember
}
func (this ActivityStreamsUrlPropertyIterator) GetIRI() *url.URL {
	return this.xmlschemaAnyURIMember
}
func (this ActivityStreamsUrlPropertyIterator) GetType() vocab.Type {
	if this.IsActivityStreamsLink() {
		return this.GetActivityStreamsLink()
	}
	if this.IsActivityStreamsMention() {
		return this.GetActivityStreamsMention()
	}
	return nil
}
func (this ActivityStreamsUrlPropertyIterator) GetXMLSchemaAnyURI() *url.URL {
	return this.xmlschemaAnyURIMember
}
func (this ActivityStreamsUrlPropertyIterator) HasAny() bool {
	return this.IsXMLSchemaAnyURI() ||
		this.IsActivityStreamsLink() ||
		this.IsActivityStreamsMention()
}
func (this ActivityStreamsUrlPropertyIterator) IsActivityStreamsLink() bool {
	return this.activitystreamsLinkMember != nil
}
func (this ActivityStreamsUrlPropertyIterator) IsActivityStreamsMention() bool {
	return this.activitystreamsMentionMember != nil
}
func (this ActivityStreamsUrlPropertyIterator) IsIRI() bool {
	return this.xmlschemaAnyURIMember != nil
}
func (this ActivityStreamsUrlPropertyIterator) IsXMLSchemaAnyURI() bool {
	return this.xmlschemaAnyURIMember != nil
}
func (this ActivityStreamsUrlPropertyIterator) JSONLDContext() map[string]string {
	m := map[string]string{"https://www.w3.org/ns/activitystreams": this.alias}
	var child map[string]string
	if this.IsActivityStreamsLink() {
		child = this.GetActivityStreamsLink().JSONLDContext()
	} else if this.IsActivityStreamsMention() {
		child = this.GetActivityStreamsMention().JSONLDContext()
	}
	for k, v := range child {
		m[k] = v
	}
	return m
}
func (this ActivityStreamsUrlPropertyIterator) KindIndex() int {
	if this.IsXMLSchemaAnyURI() {
		return 0
	}
	if this.IsActivityStreamsLink() {
		return 1
	}
	if this.IsActivityStreamsMention() {
		return 2
	}
	if this.IsIRI() {
		return -2
	}
	return -1
}
func (this ActivityStreamsUrlPropertyIterator) LessThan(o vocab.ActivityStreamsUrlPropertyIterator) bool {
	idx1 := this.KindIndex()
	idx2 := o.KindIndex()
	if idx1 < idx2 {
		return true
	} else if idx1 > idx2 {
		return false
	} else if this.IsXMLSchemaAnyURI() {
		return anyuri.LessAnyURI(this.GetXMLSchemaAnyURI(), o.GetXMLSchemaAnyURI())
	} else if this.IsActivityStreamsLink() {
		return this.GetActivityStreamsLink().LessThan(o.GetActivityStreamsLink())
	} else if this.IsActivityStreamsMention() {
		return this.GetActivityStreamsMention().LessThan(o.GetActivityStreamsMention())
	}
	return false
}
func (this ActivityStreamsUrlPropertyIterator) Name() string {
	if len(this.alias) > 0 {
		return this.alias + ":" + "ActivityStreamsUrl"
	} else {
		return "ActivityStreamsUrl"
	}
}
func (this ActivityStreamsUrlPropertyIterator) Next() vocab.ActivityStreamsUrlPropertyIterator {
	if this.myIdx+1 >= this.parent.Len() {
		return nil
	} else {
		return this.parent.At(this.myIdx + 1)
	}
}
func (this ActivityStreamsUrlPropertyIterator) Prev() vocab.ActivityStreamsUrlPropertyIterator {
	if this.myIdx-1 < 0 {
		return nil
	} else {
		return this.parent.At(this.myIdx - 1)
	}
}
func (this *ActivityStreamsUrlPropertyIterator) SetActivityStreamsLink(v vocab.ActivityStreamsLink) {
	this.clear()
	this.activitystreamsLinkMember = v
}
func (this *ActivityStreamsUrlPropertyIterator) SetActivityStreamsMention(v vocab.ActivityStreamsMention) {
	this.clear()
	this.activitystreamsMentionMember = v
}
func (this *ActivityStreamsUrlPropertyIterator) SetIRI(v *url.URL) {
	this.clear()
	this.SetXMLSchemaAnyURI(v)
}
func (this *ActivityStreamsUrlPropertyIterator) SetType(t vocab.Type) error {
	if v, ok := t.(vocab.ActivityStreamsLink); ok {
		this.SetActivityStreamsLink(v)
		return nil
	}
	if v, ok := t.(vocab.ActivityStreamsMention); ok {
		this.SetActivityStreamsMention(v)
		return nil
	}
	return fmt.Errorf("illegal type to set on ActivityStreamsUrl property: %T", t)
}