Inheritance: DebuggerMarshalByRefObject
Exemplo n.º 1
0
        protected TargetObject GetMember(ScriptingContext context, Thread target,
						  TargetMemberInfo member)
        {
            if (member is TargetPropertyInfo)
                return GetProperty (context, (TargetPropertyInfo) member);
            else if (member is TargetFieldInfo)
                return GetField (target, (TargetFieldInfo) member);
            else
                throw new ScriptingException ("Member `{0}' is of unknown type {1}",
                                  Name, member.GetType ());
        }
		public MemberReference (TargetMemberInfo member, TargetType type)
		{
			Member = member;
			DeclaringType = type;
		}
Exemplo n.º 3
0
        public StructAccessExpression(TargetStructType type,
					       TargetStructObject instance,
					       TargetMemberInfo member)
        {
            this.Type = type;
            this.Member = member;
            this.instance = instance;
            resolved = true;
        }
Exemplo n.º 4
0
        protected string FormatMember(string prefix, TargetMemberInfo member,
					       bool is_static, Hashtable hash)
        {
            string tname = member.Type != null ? member.Type.Name : "<unknown type>";
            TargetFieldInfo fi = member as TargetFieldInfo;
            if ((fi != null) && fi.HasConstValue)
                return String.Format (
                    "{0}   const {1} {2} = {3}", prefix, tname, member.Name, fi.ConstValue);
            else if (is_static)
                return String.Format (
                    "{0}   static {1} {2}", prefix, tname, member.Name);
            else
                return String.Format (
                    "{0}   {1} {2}", prefix, tname, member.Name);
        }