Exemple #1
0
 public void AddType(XType type)
 {
     throw new Exception("The method or operation is not implemented.");
 }
Exemple #2
0
 /// <summary>Compares the type of this struct to another type.</summary>
 /// <param name="otherType">otherType the type to compare this type to.</param>
 /// <returns>true if this struct is of the specified type.</returns>
 public bool IsType(XType otherType)
 {
     return(type.Equals(otherType));
 }
Exemple #3
0
 ///<summary>Constructs the StructValue with default length.</summary>
 ///<param name="type">the type of the struct (or the action or event if
 ///this is a message).</param>
 ///<param name="vf">the value factory for this struct</param>
 public StructValue(XType type, ValueFactory vf)
     : this(type, vf, 0)
 {
     // nothing to do.
 }
Exemple #4
0
 ///<summary>Sets the super type of this type. If struct A extends B, then
 ///B is the super type of A.</summary>
 ///<param name="superType"></param>
 public void SetSuperType(XType superType)
 {
     CheckNotLocked();
     this.superType = superType;
 }
Exemple #5
0
        ///<summary>Checks whether this type is assignment compatible with other. This
        ///means that other is a subclass of this.</summary>
        ///<param name="other"></param>
        ///<returns>true if this type is assignable from other</returns>

        public bool IsAssignableFrom(XType other)
        {
            return(other != null && (this.Equals(other) || IsAssignableFrom(other.SuperType())));
        }
Exemple #6
0
 public void SetResult(XType rType)
 {
     CheckNotLocked();
     this.rType = rType;
 }