public void SetGuidValue(string columnName, System.Guid?value) { NullableGuid tempvalue = value.HasValue ? new NullableGuid(Common.ParseGuid(value.Value.ToByteArray(), true)) : null; { CommonPINVOKE.DataRow_SetGuidValue__SWIG_1(swigCPtr, columnName, NullableGuid.getCPtr(tempvalue)); if (CommonPINVOKE.SWIGPendingException.Pending) { throw CommonPINVOKE.SWIGPendingException.Retrieve(); } } }
public System.Guid? ValueAsGuid(string columnName) { global::System.IntPtr cPtr = CommonPINVOKE.DataRow_ValueAsGuid__SWIG_1(swigCPtr, columnName); if (CommonPINVOKE.SWIGPendingException.Pending) { throw CommonPINVOKE.SWIGPendingException.Retrieve(); } using (NullableGuid tempGuid = (cPtr == global::System.IntPtr.Zero) ? null : new NullableGuid(cPtr, false)) { if (!(tempGuid?.HasValue() ?? false)) { return(null); } byte[] data = new byte[16]; Common.GetGuidBytes(tempGuid.GetValueOrDefault(), data); return(new System.Guid(data)); } }
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(NullableGuid obj) { return((obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr); }