Extended .NET SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
OdUnitsFormatterTool.cs
Go to the documentation of this file.
1//------------------------------------------------------------------------------
2// <auto-generated />
3//
4// This file was automatically generated by SWIG (http://www.swig.org).
5// Version 4.0.2
6//
7// Do not make changes to this file unless you know what you are doing--modify
8// the SWIG interface file instead.
9//------------------------------------------------------------------------------
10
11namespace Teigha.Core {
12
13using System;
14using System.Runtime.InteropServices;
15
16public class OdUnitsFormatterTool : global::System.IDisposable {
17 private Object locker = new Object();
18 private HandleRef swigCPtr;
19 protected bool swigCMemOwn;
20 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
21 public OdUnitsFormatterTool(IntPtr cPtr, bool cMemoryOwn) {
22 swigCMemOwn = cMemoryOwn;
23 swigCPtr = new HandleRef(this, cPtr);
24 }
25 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
26 public static HandleRef getCPtr(OdUnitsFormatterTool obj) {
27 return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
28 }
29
31 Dispose(false);
32 }
33
34 public void Dispose() {
35 Dispose(true);
36 global::System.GC.SuppressFinalize(this);
37 }
38
39 protected virtual void Dispose(bool disposing) {
40 lock(this) {
41 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
42 if (swigCMemOwn) {
43 swigCMemOwn = false;
45 }
46 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
47 }
48 }
49 }
50
51 public OdUnitsFormatterTool() : this(GlobalsPINVOKE.new_OdUnitsFormatterTool(), true) {
53 }
54
55 public static String formatDecimal(double value, int precision, int dimzin, String decsep, String thsep) {
56 string ret = GlobalsPINVOKE.OdUnitsFormatterTool_formatDecimal__SWIG_0(value, precision, dimzin, decsep, thsep);
58 return ret;
59}
60
61 public static String formatDecimal(double value, int precision, int dimzin, String decsep) {
62 string ret = GlobalsPINVOKE.OdUnitsFormatterTool_formatDecimal__SWIG_1(value, precision, dimzin, decsep);
64 return ret;
65}
66
67 public static double angle(char[] /*SIMPLE_REFARRAY*/ buf, bool refuseDots) {
68 double ret = GlobalsPINVOKE.OdUnitsFormatterTool_angle__SWIG_0(buf, refuseDots);
70 return ret;
71 }
72
73 public static double angle(char[] /*SIMPLE_REFARRAY*/ buf) {
76 return ret;
77 }
78
79 public static int toInt(String sValue, int nMinValid, int nMaxValid) {
80 int ret = GlobalsPINVOKE.OdUnitsFormatterTool_toInt__SWIG_0(sValue, nMinValid, nMaxValid);
82 return ret;
83 }
84
85 public static int toInt(String sValue, int nMinValid) {
86 int ret = GlobalsPINVOKE.OdUnitsFormatterTool_toInt__SWIG_1(sValue, nMinValid);
88 return ret;
89 }
90
91 public static int toInt(String sValue) {
94 return ret;
95 }
96
97 public static bool isZero(double v, int precision) {
98 bool ret = GlobalsPINVOKE.OdUnitsFormatterTool_isZero(v, precision);
100 return ret;
101 }
102
103 public static String formatArchitectural(bool isNegative, int feet, int entier, int numerator, int denominator, int dimzin, int mode) {
104 string ret = GlobalsPINVOKE.OdUnitsFormatterTool_formatArchitectural(isNegative, feet, entier, numerator, denominator, dimzin, mode);
106 return ret;
107}
108
109 public static bool negative(char[] /*SIMPLE_REFARRAY*/ buf) {
112 return ret;
113 }
114
115 public static double integer(char[] /*SIMPLE_REFARRAY*/ buf) {
118 return ret;
119 }
120
121 public static double number(char[] /*SIMPLE_REFARRAY*/ buf, bool /*SIMPLETYPE*/ pHasDot, bool /*SIMPLETYPE*/ pHasExponent) {
122 double ret = GlobalsPINVOKE.OdUnitsFormatterTool_number__SWIG_0(buf, pHasDot /*SIMPLETYPE*/, pHasExponent /*SIMPLETYPE*/);
124 return ret;
125 }
126
127 public static double number(char[] /*SIMPLE_REFARRAY*/ buf, bool /*SIMPLETYPE*/ pHasDot) {
128 double ret = GlobalsPINVOKE.OdUnitsFormatterTool_number__SWIG_1(buf, pHasDot /*SIMPLETYPE*/);
130 return ret;
131 }
132
133 public static double number(char[] /*SIMPLE_REFARRAY*/ buf) {
136 return ret;
137 }
138
139 public static void fraction(double value, out int entier, out int numerator, out int denominator, int precision) {
140 GlobalsPINVOKE.OdUnitsFormatterTool_fraction(value, out entier, out numerator, out denominator, precision);
142 }
143
144 public static double base_denominator(int prec, double base_) {
147 return ret;
148 }
149
150 public static double linear_denominator(int prec) {
153 return ret;
154 }
155
156 public static bool digit(char /*SIMPLETYPE*/ c) {
157 bool ret = GlobalsPINVOKE.OdUnitsFormatterTool_digit(c /*SIMPLETYPE*/);
159 return ret;
160 }
161
162 public static double denominator(int prec) {
165 return ret;
166 }
167
168 public static void decomp(double v, out int degs, out int mins, out double secs, int prec) {
169 GlobalsPINVOKE.OdUnitsFormatterTool_decomp(v, out degs, out mins, out secs, prec);
171 }
172
173 public static String format(int degs, int mins, double secs, int prec) {
174 string ret = GlobalsPINVOKE.OdUnitsFormatterTool_format(degs, mins, secs, prec);
176 return ret;
177}
178
179 public static String next(ref string list, String delim) {
180IntPtr tmp_list = Marshal.StringToCoTaskMemUni(list);
181 IntPtr saved_list = tmp_list;
182 try {
183 string ret = GlobalsPINVOKE.OdUnitsFormatterTool_next__SWIG_0(ref tmp_list, delim);
185 return ret;
186} finally {
187if (tmp_list != saved_list) list = Marshal.PtrToStringUni(tmp_list);
188 }
189 }
190
191 public static String next(ref string list) {
192IntPtr tmp_list = Marshal.StringToCoTaskMemUni(list);
193 IntPtr saved_list = tmp_list;
194 try {
195 string ret = GlobalsPINVOKE.OdUnitsFormatterTool_next__SWIG_1(ref tmp_list);
197 return ret;
198} finally {
199if (tmp_list != saved_list) list = Marshal.PtrToStringUni(tmp_list);
200 }
201 }
202
203 public static int countOccurences(String string_, char /*SIMPLETYPE*/ delim) {
204 int ret = GlobalsPINVOKE.OdUnitsFormatterTool_countOccurences__SWIG_0(string_, delim /*SIMPLETYPE*/);
206 return ret;
207 }
208
209 public static int countOccurences(String string_) {
212 return ret;
213 }
214
219 public static string vb_format(int degs, int mins, double secs, int prec) { return format(degs, mins, secs, prec); }
220
221}
222
223}
static global::System.Exception Retrieve()
static String OdUnitsFormatterTool_formatDecimal__SWIG_1(double jarg1, int jarg2, int jarg3, [MarshalAs(UnmanagedType.LPWStr)]String jarg4)
static int OdUnitsFormatterTool_countOccurences__SWIG_1([MarshalAs(UnmanagedType.LPWStr)]String jarg1)
static double OdUnitsFormatterTool_number__SWIG_2([In, MarshalAs(UnmanagedType.LPArray)]char[] jarg1)
static void delete_OdUnitsFormatterTool(global::System.Runtime.InteropServices.HandleRef jarg1)
static String OdUnitsFormatterTool_formatArchitectural(bool jarg1, int jarg2, int jarg3, int jarg4, int jarg5, int jarg6, int jarg7)
static double OdUnitsFormatterTool_number__SWIG_0([In, MarshalAs(UnmanagedType.LPArray)]char[] jarg1, bool jarg2, bool jarg3)
static String OdUnitsFormatterTool_formatDecimal__SWIG_0(double jarg1, int jarg2, int jarg3, [MarshalAs(UnmanagedType.LPWStr)]String jarg4, [MarshalAs(UnmanagedType.LPWStr)]String jarg5)
static double OdUnitsFormatterTool_linear_denominator(int jarg1)
static double OdUnitsFormatterTool_integer([In, MarshalAs(UnmanagedType.LPArray)]char[] jarg1)
static double OdUnitsFormatterTool_denominator(int jarg1)
static int OdUnitsFormatterTool_toInt__SWIG_0([MarshalAs(UnmanagedType.LPWStr)]String jarg1, int jarg2, int jarg3)
static void OdUnitsFormatterTool_fraction(double jarg1, out int jarg2, out int jarg3, out int jarg4, int jarg5)
static int OdUnitsFormatterTool_toInt__SWIG_1([MarshalAs(UnmanagedType.LPWStr)]String jarg1, int jarg2)
static bool OdUnitsFormatterTool_digit(char jarg1)
static double OdUnitsFormatterTool_base_denominator(int jarg1, double jarg2)
static bool OdUnitsFormatterTool_isZero(double jarg1, int jarg2)
static String OdUnitsFormatterTool_next__SWIG_1(ref IntPtr jarg1)
static double OdUnitsFormatterTool_angle__SWIG_0([In, MarshalAs(UnmanagedType.LPArray)]char[] jarg1, bool jarg2)
static String OdUnitsFormatterTool_next__SWIG_0(ref IntPtr jarg1, [MarshalAs(UnmanagedType.LPWStr)]String jarg2)
static double OdUnitsFormatterTool_angle__SWIG_1([In, MarshalAs(UnmanagedType.LPArray)]char[] jarg1)
static double OdUnitsFormatterTool_number__SWIG_1([In, MarshalAs(UnmanagedType.LPArray)]char[] jarg1, bool jarg2)
static String OdUnitsFormatterTool_format(int jarg1, int jarg2, double jarg3, int jarg4)
static void OdUnitsFormatterTool_decomp(double jarg1, out int jarg2, out int jarg3, out double jarg4, int jarg5)
static int OdUnitsFormatterTool_toInt__SWIG_2([MarshalAs(UnmanagedType.LPWStr)]String jarg1)
static bool OdUnitsFormatterTool_negative([In, MarshalAs(UnmanagedType.LPArray)]char[] jarg1)
static int OdUnitsFormatterTool_countOccurences__SWIG_0([MarshalAs(UnmanagedType.LPWStr)]String jarg1, char jarg2)
static int toInt(String sValue, int nMinValid)
static int toInt(String sValue, int nMinValid, int nMaxValid)
static String format(int degs, int mins, double secs, int prec)
static double number(char[] buf)
static int countOccurences(String string_)
static double base_denominator(int prec, double base_)
static void fraction(double value, out int entier, out int numerator, out int denominator, int precision)
static string vb_format(int degs, int mins, double secs, int prec)
static double angle(char[] buf)
static bool isZero(double v, int precision)
static double number(char[] buf, bool pHasDot, bool pHasExponent)
static String formatDecimal(double value, int precision, int dimzin, String decsep, String thsep)
static String formatArchitectural(bool isNegative, int feet, int entier, int numerator, int denominator, int dimzin, int mode)
static void decomp(double v, out int degs, out int mins, out double secs, int prec)
static double integer(char[] buf)
static String formatDecimal(double value, int precision, int dimzin, String decsep)
OdUnitsFormatterTool(IntPtr cPtr, bool cMemoryOwn)
virtual void Dispose(bool disposing)
static int countOccurences(String string_, char delim)
static int toInt(String sValue)
static HandleRef getCPtr(OdUnitsFormatterTool obj)
static double angle(char[] buf, bool refuseDots)
static String next(ref string list, String delim)
static double linear_denominator(int prec)
static String next(ref string list)
static double number(char[] buf, bool pHasDot)