github.com/hspan/go-ole@v0.0.0/safearray_func.go (about) 1 // +build !windows 2 3 package ole 4 5 import ( 6 "unsafe" 7 ) 8 9 // safeArrayAccessData returns raw array pointer. 10 // 11 // AKA: SafeArrayAccessData in Windows API. 12 func safeArrayAccessData(safearray *SafeArray) (uintptr, error) { 13 return uintptr(0), NewError(E_NOTIMPL) 14 } 15 16 // safeArrayUnaccessData releases raw array. 17 // 18 // AKA: SafeArrayUnaccessData in Windows API. 19 func safeArrayUnaccessData(safearray *SafeArray) error { 20 return NewError(E_NOTIMPL) 21 } 22 23 // safeArrayAllocData allocates SafeArray. 24 // 25 // AKA: SafeArrayAllocData in Windows API. 26 func safeArrayAllocData(safearray *SafeArray) error { 27 return NewError(E_NOTIMPL) 28 } 29 30 // safeArrayAllocDescriptor allocates SafeArray. 31 // 32 // AKA: SafeArrayAllocDescriptor in Windows API. 33 func safeArrayAllocDescriptor(dimensions uint32) (*SafeArray, error) { 34 return nil, NewError(E_NOTIMPL) 35 } 36 37 // safeArrayAllocDescriptorEx allocates SafeArray. 38 // 39 // AKA: SafeArrayAllocDescriptorEx in Windows API. 40 func safeArrayAllocDescriptorEx(variantType VT, dimensions uint32) (*SafeArray, error) { 41 return nil, NewError(E_NOTIMPL) 42 } 43 44 // safeArrayCopy returns copy of SafeArray. 45 // 46 // AKA: SafeArrayCopy in Windows API. 47 func safeArrayCopy(original *SafeArray) (*SafeArray, error) { 48 return nil, NewError(E_NOTIMPL) 49 } 50 51 // safeArrayCopyData duplicates SafeArray into another SafeArray object. 52 // 53 // AKA: SafeArrayCopyData in Windows API. 54 func safeArrayCopyData(original *SafeArray, duplicate *SafeArray) error { 55 return NewError(E_NOTIMPL) 56 } 57 58 // safeArrayCreate creates SafeArray. 59 // 60 // AKA: SafeArrayCreate in Windows API. 61 func safeArrayCreate(variantType VT, dimensions uint32, bounds *SafeArrayBound) (*SafeArray, error) { 62 return nil, NewError(E_NOTIMPL) 63 } 64 65 // safeArrayCreateEx creates SafeArray. 66 // 67 // AKA: SafeArrayCreateEx in Windows API. 68 func safeArrayCreateEx(variantType VT, dimensions uint32, bounds *SafeArrayBound, extra uintptr) (*SafeArray, error) { 69 return nil, NewError(E_NOTIMPL) 70 } 71 72 // safeArrayCreateVector creates SafeArray. 73 // 74 // AKA: SafeArrayCreateVector in Windows API. 75 func safeArrayCreateVector(variantType VT, lowerBound int32, length uint32) (*SafeArray, error) { 76 return nil, NewError(E_NOTIMPL) 77 } 78 79 // safeArrayCreateVectorEx creates SafeArray. 80 // 81 // AKA: SafeArrayCreateVectorEx in Windows API. 82 func safeArrayCreateVectorEx(variantType VT, lowerBound int32, length uint32, extra uintptr) (*SafeArray, error) { 83 return nil, NewError(E_NOTIMPL) 84 } 85 86 // safeArrayDestroy destroys SafeArray object. 87 // 88 // AKA: SafeArrayDestroy in Windows API. 89 func safeArrayDestroy(safearray *SafeArray) error { 90 return NewError(E_NOTIMPL) 91 } 92 93 // safeArrayDestroyData destroys SafeArray object. 94 // 95 // AKA: SafeArrayDestroyData in Windows API. 96 func safeArrayDestroyData(safearray *SafeArray) error { 97 return NewError(E_NOTIMPL) 98 } 99 100 // safeArrayDestroyDescriptor destroys SafeArray object. 101 // 102 // AKA: SafeArrayDestroyDescriptor in Windows API. 103 func safeArrayDestroyDescriptor(safearray *SafeArray) error { 104 return NewError(E_NOTIMPL) 105 } 106 107 // safeArrayGetDim is the amount of dimensions in the SafeArray. 108 // 109 // SafeArrays may have multiple dimensions. Meaning, it could be 110 // multidimensional array. 111 // 112 // AKA: SafeArrayGetDim in Windows API. 113 func safeArrayGetDim(safearray *SafeArray) (*uint32, error) { 114 u := uint32(0) 115 return &u, NewError(E_NOTIMPL) 116 } 117 118 // safeArrayGetElementSize is the element size in bytes. 119 // 120 // AKA: SafeArrayGetElemsize in Windows API. 121 func safeArrayGetElementSize(safearray *SafeArray) (*uint32, error) { 122 u := uint32(0) 123 return &u, NewError(E_NOTIMPL) 124 } 125 126 // safeArrayGetElement retrieves element at given index. 127 func safeArrayGetElement(safearray *SafeArray, index int32, pv unsafe.Pointer) error { 128 return NewError(E_NOTIMPL) 129 } 130 131 // safeArrayGetElement retrieves element at given index and converts to string. 132 func safeArrayGetElementString(safearray *SafeArray, index int32) (string, error) { 133 return "", NewError(E_NOTIMPL) 134 } 135 136 // safeArrayGetIID is the InterfaceID of the elements in the SafeArray. 137 // 138 // AKA: SafeArrayGetIID in Windows API. 139 func safeArrayGetIID(safearray *SafeArray) (*GUID, error) { 140 return nil, NewError(E_NOTIMPL) 141 } 142 143 // safeArrayGetLBound returns lower bounds of SafeArray. 144 // 145 // SafeArrays may have multiple dimensions. Meaning, it could be 146 // multidimensional array. 147 // 148 // AKA: SafeArrayGetLBound in Windows API. 149 func safeArrayGetLBound(safearray *SafeArray, dimension uint32) (int32, error) { 150 return int32(0), NewError(E_NOTIMPL) 151 } 152 153 // safeArrayGetUBound returns upper bounds of SafeArray. 154 // 155 // SafeArrays may have multiple dimensions. Meaning, it could be 156 // multidimensional array. 157 // 158 // AKA: SafeArrayGetUBound in Windows API. 159 func safeArrayGetUBound(safearray *SafeArray, dimension uint32) (int32, error) { 160 return int32(0), NewError(E_NOTIMPL) 161 } 162 163 // safeArrayGetVartype returns data type of SafeArray. 164 // 165 // AKA: SafeArrayGetVartype in Windows API. 166 func safeArrayGetVartype(safearray *SafeArray) (uint16, error) { 167 return uint16(0), NewError(E_NOTIMPL) 168 } 169 170 // safeArrayLock locks SafeArray for reading to modify SafeArray. 171 // 172 // This must be called during some calls to ensure that another process does not 173 // read or write to the SafeArray during editing. 174 // 175 // AKA: SafeArrayLock in Windows API. 176 func safeArrayLock(safearray *SafeArray) error { 177 return NewError(E_NOTIMPL) 178 } 179 180 // safeArrayUnlock unlocks SafeArray for reading. 181 // 182 // AKA: SafeArrayUnlock in Windows API. 183 func safeArrayUnlock(safearray *SafeArray) error { 184 return NewError(E_NOTIMPL) 185 } 186 187 // safeArrayPutElement stores the data element at the specified location in the 188 // array. 189 // 190 // AKA: SafeArrayPutElement in Windows API. 191 func safeArrayPutElement(safearray *SafeArray, index int64, element uintptr) error { 192 return NewError(E_NOTIMPL) 193 } 194 195 // safeArrayGetRecordInfo accesses IRecordInfo info for custom types. 196 // 197 // AKA: SafeArrayGetRecordInfo in Windows API. 198 // 199 // XXX: Must implement IRecordInfo interface for this to return. 200 func safeArrayGetRecordInfo(safearray *SafeArray) (interface{}, error) { 201 return nil, NewError(E_NOTIMPL) 202 } 203 204 // safeArraySetRecordInfo mutates IRecordInfo info for custom types. 205 // 206 // AKA: SafeArraySetRecordInfo in Windows API. 207 // 208 // XXX: Must implement IRecordInfo interface for this to return. 209 func safeArraySetRecordInfo(safearray *SafeArray, recordInfo interface{}) error { 210 return NewError(E_NOTIMPL) 211 }