Extended .NET SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
OdBaseFileBuf.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
17 private Object locker = new Object();
18 private HandleRef swigCPtr;
19 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
20 public OdBaseFileBuf(IntPtr cPtr, bool cMemoryOwn) : base(GlobalsPINVOKE.OdBaseFileBuf_SWIGUpcast(cPtr), cMemoryOwn) {
21 swigCPtr = new HandleRef(this, cPtr);
22 }
23
24 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
25 public static HandleRef getCPtr(OdBaseFileBuf obj) {
26 return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
27 }
28
29 protected override void Dispose(bool disposing) {
30 lock(this) {
31 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
32 if (swigCMemOwn) {
33 swigCMemOwn = false;
35 }
36 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
37 }
38 base.Dispose(disposing);
39 }
40 }
41
42 public virtual void open(String filename, FileShareMode shareMode, FileAccessMode accessMode, FileCreationDisposition creationDisposition) {
43 GlobalsPINVOKE.OdBaseFileBuf_open(swigCPtr, filename, (int)shareMode, (int)accessMode, (int)creationDisposition);
45 }
46
47 public virtual void close() {
50 }
51
52 public virtual String fileName() {
53 string ret = GlobalsPINVOKE.OdBaseFileBuf_fileName(swigCPtr);
55 return ret;
56}
57
58 public virtual UInt32 getShareMode() {
59// test csout
60 /*SIMPLETYPE*/
61 UInt32 ret = GlobalsPINVOKE.OdBaseFileBuf_getShareMode(swigCPtr);
63 return ret;
64 }
65
66 public virtual UInt64 length() {
67// test csout
68 /*SIMPLETYPE*/
69 UInt64 ret = GlobalsPINVOKE.OdBaseFileBuf_length(swigCPtr);
71 return ret;
72 }
73
74 public virtual UInt64 seek(Int64 /*SIMPLETYPE*/ offset, FilerSeekType seekType) {
75// test csout
76 /*SIMPLETYPE*/
77 UInt64 ret = GlobalsPINVOKE.OdBaseFileBuf_seek(swigCPtr, offset /*SIMPLETYPE*/, (int)seekType);
79 return ret;
80 }
81
82 public virtual UInt64 tell() {
83// test csout
84 /*SIMPLETYPE*/
85 UInt64 ret = GlobalsPINVOKE.OdBaseFileBuf_tell(swigCPtr);
87 return ret;
88 }
89
90 public virtual bool isEof() {
91 bool ret = GlobalsPINVOKE.OdBaseFileBuf_isEof(swigCPtr);
93 return ret;
94 }
95
96 public virtual byte getByte() {
97// test csout
98 /*SIMPLETYPE*/
99 byte ret = GlobalsPINVOKE.OdBaseFileBuf_getByte(swigCPtr);
101 return ret;
102 }
103
104 private void getBytes(IntPtr buffer, UInt32 /*SIMPLETYPE*/ numBytes) {
105 GlobalsPINVOKE.OdBaseFileBuf_getBytes(swigCPtr, buffer, numBytes /*SIMPLETYPE*/);
107 }
108
109 public virtual void putByte(byte /*SIMPLETYPE*/ value) {
110 GlobalsPINVOKE.OdBaseFileBuf_putByte(swigCPtr, value /*SIMPLETYPE*/);
112 }
113
114 public virtual void putBytes(byte[] /*SIMPLEFIXED_ARRAY*/ buffer) {
115IntPtr p_buffer=Teigha.Core.Helpers.MarshalbyteFixedArray(buffer);
116 try {
117 GlobalsPINVOKE.OdBaseFileBuf_putBytes(swigCPtr, p_buffer);
119 } finally {
120Marshal.FreeCoTaskMem(p_buffer);
121 }
122 }
123
124 public virtual void truncate() {
127 }
128
129 public virtual void copyDataTo(OdStreamBuf pDestination, UInt64 /*SIMPLETYPE*/ sourceStart, UInt64 /*SIMPLETYPE*/ sourceEnd) {
130 GlobalsPINVOKE.OdBaseFileBuf_copyDataTo(swigCPtr, OdStreamBuf.getCPtr(pDestination), sourceStart /*SIMPLETYPE*/, sourceEnd /*SIMPLETYPE*/);
132 }
133
134 protected static string getRealClassName(IntPtr /*SIMPLETYPE*/ ptr) {
135 string ret = GlobalsPINVOKE.OdBaseFileBuf_getRealClassName(ptr /*SIMPLETYPE*/);
137 return ret;
138 }
139
140}
141
142}
static global::System.Exception Retrieve()
static bool OdBaseFileBuf_isEof(HandleRef jarg1)
static void OdBaseFileBuf_getBytes(HandleRef jarg1, IntPtr jarg2, UInt32 jarg3)
static void OdBaseFileBuf_copyDataTo(HandleRef jarg1, HandleRef jarg2, UInt64 jarg3, UInt64 jarg4)
static UInt32 OdBaseFileBuf_getShareMode(HandleRef jarg1)
static UInt64 OdBaseFileBuf_length(HandleRef jarg1)
static string OdBaseFileBuf_getRealClassName(IntPtr jarg1)
static UInt64 OdBaseFileBuf_seek(HandleRef jarg1, Int64 jarg2, int jarg3)
static byte OdBaseFileBuf_getByte(HandleRef jarg1)
static void OdBaseFileBuf_truncate(HandleRef jarg1)
static void OdBaseFileBuf_putByte(HandleRef jarg1, byte jarg2)
static void delete_OdBaseFileBuf(HandleRef jarg1)
static void OdBaseFileBuf_close(HandleRef jarg1)
static void OdBaseFileBuf_open(HandleRef jarg1, [MarshalAs(UnmanagedType.LPWStr)]String jarg2, int jarg3, int jarg4, int jarg5)
static UInt64 OdBaseFileBuf_tell(HandleRef jarg1)
static String OdBaseFileBuf_fileName(HandleRef jarg1)
static void OdBaseFileBuf_putBytes(HandleRef jarg1, IntPtr jarg2)
virtual UInt64 length()
virtual UInt64 seek(Int64 offset, FilerSeekType seekType)
OdBaseFileBuf(IntPtr cPtr, bool cMemoryOwn)
virtual String fileName()
virtual void copyDataTo(OdStreamBuf pDestination, UInt64 sourceStart, UInt64 sourceEnd)
static HandleRef getCPtr(OdBaseFileBuf obj)
virtual UInt32 getShareMode()
override void Dispose(bool disposing)
virtual UInt64 tell()
static string getRealClassName(IntPtr ptr)
virtual void putByte(byte value)
virtual void open(String filename, FileShareMode shareMode, FileAccessMode accessMode, FileCreationDisposition creationDisposition)
virtual void putBytes(byte[] buffer)
static HandleRef getCPtr(OdStreamBuf obj)
Definition: OdStreamBuf.cs:25