Commit Graph

30 Commits (81292aca1de7e254540602c9db6c130b09597683)

Author SHA1 Message Date
dahall 514e974703 Modified GenericStringMarshaler type constraint to ISimpleMemoryMethods 2020-04-11 16:10:33 -06:00
dahall cd46adfb6b Added GenericStringMarshalerBase and GenericStringMarshaler as custom string marshalers that can be typed against an IMemoryMethods implementation. The converted LocalStringMarshaler and CoTaskMemStringMarshaler to use that new class. 2020-04-07 12:43:44 -06:00
dahall 3cf49c0749 Introduced base class for SafeAnysizeStruct to enable reuse with objects that don't use a single field to determine the length of the array. 2020-04-07 09:34:13 -06:00
dahall 2e9935667a Removed generic constraint so classes could be processed and changed ctor param from int to SizeT for consistency with base class. 2020-03-31 16:01:47 -06:00
dahall cc7170875f Fix and test for #101 - Bug when using SafeAnysizeStruct. 2020-01-17 07:54:15 -07:00
David Hall 8ca39f3530 On IntPtr constructor, removed copying of memory from orig pointer and now just use unowned pointer. 2019-11-27 14:45:38 -07:00
David Hall a94e60820b Reworked memory manipulation functions in InteropExtensions and IntPtrConverter to use new marshaling directives and to drive consistency of use across libs (i.e. call same method to do same work). 2019-11-19 12:52:44 -07:00
David Hall 9d02afc6e1 Added SafeAnysizeStructMarshaler which is a IVanaraMarshaler implementation for SafeAnysizeStruct<T> 2019-11-16 15:50:23 -07:00
David Hall 296a559eda Added SafeAnysizeStruct to help marshal stuctures with a 1-element field at the end that can be variable size. Adjusted all structs of this type to use this to marshal along with tests and supported classes.
BREAKING CHANGE: This forced the removal of PTOKEN_PRIVILEGES as that functionality is now in a shared marshaling class.
2019-11-03 16:02:54 -07:00
David Hall cd0819e08b Added headerSize to constructors' parameters from base 2019-09-30 20:36:28 -06:00
David Hall 6db3256757 Added custom marshaler for arrays of string pointers 2019-09-16 07:57:52 -06:00
David Hall c532e6061f Made indexer related properties virtual 2019-08-22 13:57:03 -06:00
David Hall c3521b7742 MAJOR BREAKING CHANGEs:
1) Obsoleted Vanara.Extensions.InteropExtensions.StructureToPtr for a name change to MarshalToPtr for consistency.
2) Added parameter to all methods reading memory that allows developer to indicate size of allocated memory they read from.
3) Enabled the ability to read/write enum values from memory in all extension methods.
4) Added Write methods for writing to memory
2019-08-17 21:13:57 -06:00
David Hall ffed6e252a Added constructor to allow for ReadOnly use. 2019-07-03 14:45:15 -06:00
David Hall 2c1b24e3e1 Fixed bug in Insert 2019-06-09 10:00:16 -06:00
David Hall 8d211da1de Fixed bugs on Insert and array set methods 2019-05-09 15:56:31 -06:00
David Hall f5ad3f0755 Extracted SafeNativeArrayBase from SafeNativeArray that allows for a different memory manager to be used and enhances/fixes the ability to insert a header before the array. 2019-05-08 09:30:06 -06:00
David Hall 348fc7b7f7 Added class to handle linked list of native structures in memory 2019-04-24 08:28:18 -06:00
David Hall 0383068abe Added documentation and protected constructor to allocate just raw memory 2019-04-24 08:27:31 -06:00
David Hall 8770bc4bae Updated documentation, added mem-zeroing on array set 2019-04-24 08:26:50 -06:00
David Hall 3a56122887 Updated documentation 2019-04-17 12:51:11 -06:00
David Hall 5597d959c2 Updated documentation 2019-04-17 12:25:05 -06:00
David Hall 8a1355b0af Updated comments 2018-11-28 12:33:55 -07:00
David Hall c5467dfb7e Another 2.0 major commit. All tests working. 2018-11-19 21:18:50 -07:00
David Hall 627c6d2314 2.0 Checkin - Buildable 2018-10-26 12:24:07 -06:00
David Hall 0d8b96fe9b Corrected XML documentation errors 2018-04-03 18:35:18 -06:00
David Hall e6910dc9a9 Fixed bug with CoTaskMemStringMarshaler being used for return values and is never called. Added marshaler to places where appropriate. 2018-01-15 09:41:05 -07:00
David Hall 9f2d1c1c60 Added SafeElementArray class to Core to handle BLOB types 2018-01-06 16:37:05 -07:00
David Hall d33fa43e7b Minor cleaning and reorganizing 2017-11-28 09:00:10 -07:00
David Hall b44f91b5a1 Initial code push: Core, PInvoke.Shared and PInvoke.TaskSchd 2017-11-27 10:18:01 -07:00