Ejemplo n.º 1
0
 public void SetSubType(FieldSubType type)
 {
     OgrPINVOKE.FieldDefn_SetSubType(swigCPtr, (int)type);
     if (OgrPINVOKE.SWIGPendingException.Pending)
     {
         throw OgrPINVOKE.SWIGPendingException.Retrieve();
     }
 }
Ejemplo n.º 2
0
 internal static string GetExportName(string fieldName, out FieldSubType subType)
 {
     if (fieldName[0] == '#')
     {
         subType = FieldSubType.ContentList;
         return(fieldName.Substring(1));
     }
     subType = FieldSubType.General;
     return(fieldName);
 }
Ejemplo n.º 3
0
        public static string GetFieldSubTypeName(FieldSubType type)
        {
            string ret = OgrPINVOKE.GetFieldSubTypeName((int)type);

            if (OgrPINVOKE.SWIGPendingException.Pending)
            {
                throw OgrPINVOKE.SWIGPendingException.Retrieve();
            }
            return(ret);
        }
Ejemplo n.º 4
0
        public FieldSubType GetSubType()
        {
            FieldSubType ret = (FieldSubType)OgrPINVOKE.FieldDefn_GetSubType(swigCPtr);

            if (OgrPINVOKE.SWIGPendingException.Pending)
            {
                throw OgrPINVOKE.SWIGPendingException.Retrieve();
            }
            return(ret);
        }
Ejemplo n.º 5
0
        internal static string ParseImportName(string importName, FieldSubType subType)
        {
            switch (subType)
            {
            case FieldSubType.General:
                return(importName);

            case FieldSubType.ContentList:
                return(importName.Insert(0, "#"));

            default:
                throw new SnNotSupportedException("FieldSubType '" + subType + "' is not supported.");
            }
        }
Ejemplo n.º 6
0
 public void SetSubType(FieldSubType type)
 {
     OgrPINVOKE.FieldDefn_SetSubType(swigCPtr, (int)type);
     if (OgrPINVOKE.SWIGPendingException.Pending) throw OgrPINVOKE.SWIGPendingException.Retrieve();
 }
Ejemplo n.º 7
0
        public static FieldDomain CreateGlobFieldDomain(string name, string description, FieldType type, FieldSubType subtype, string glob)
        {
            IntPtr      cPtr = OgrPINVOKE.CreateGlobFieldDomain(name, description, (int)type, (int)subtype, glob);
            FieldDomain ret  = (cPtr == IntPtr.Zero) ? null : new FieldDomain(cPtr, true, ThisOwn_true());

            if (OgrPINVOKE.SWIGPendingException.Pending)
            {
                throw OgrPINVOKE.SWIGPendingException.Retrieve();
            }
            return(ret);
        }
Ejemplo n.º 8
0
        public static FieldDomain CreateRangeFieldDomain(string name, string description, FieldType type, FieldSubType subtype, double min, bool minIsInclusive, double max, double maxIsInclusive)
        {
            IntPtr      cPtr = OgrPINVOKE.CreateRangeFieldDomain(name, description, (int)type, (int)subtype, min, minIsInclusive, max, maxIsInclusive);
            FieldDomain ret  = (cPtr == IntPtr.Zero) ? null : new FieldDomain(cPtr, true, ThisOwn_true());

            if (OgrPINVOKE.SWIGPendingException.Pending)
            {
                throw OgrPINVOKE.SWIGPendingException.Retrieve();
            }
            return(ret);
        }
Ejemplo n.º 9
0
 public static string GetFieldSubTypeName(FieldSubType type)
 {
     string ret = OgrPINVOKE.GetFieldSubTypeName((int)type);
     if (OgrPINVOKE.SWIGPendingException.Pending) throw OgrPINVOKE.SWIGPendingException.Retrieve();
     return ret;
 }
Ejemplo n.º 10
0
		internal static string ParseImportName(string importName, FieldSubType subType)
		{
			switch (subType)
			{
				case FieldSubType.General:
					return importName;
				case FieldSubType.ContentList:
					return importName.Insert(0, "#");
				default:
					throw new NotImplementedException("FieldSubType '" + subType +"' is not implemented");
			}
		}
Ejemplo n.º 11
0
		internal static string GetExportName(string fieldName, out FieldSubType subType)
		{
			if (fieldName[0] == '#')
			{
				subType = FieldSubType.ContentList;
				return fieldName.Substring(1);
			}
			subType = FieldSubType.General;
			return fieldName;
		}