D
Drew
Does this return the array by value or reference? Because of DotNet's
memory handling, I don't know how I could figure this out... Is there
a way?
System::Byte Converter::ToByteArray(vector<XTBYTE>& data)[]
{
XTSIZE_T tSize = data.size();
System::Byte aData[] = new System::Byte[tSize]; // Managed
destination array
System::Byte __pin* pDest = &aData[0]; // Pin the
destination array
memcpy(pDest, &data[0], tSize);
return (aData);
}
memory handling, I don't know how I could figure this out... Is there
a way?
System::Byte Converter::ToByteArray(vector<XTBYTE>& data)[]
{
XTSIZE_T tSize = data.size();
System::Byte aData[] = new System::Byte[tSize]; // Managed
destination array
System::Byte __pin* pDest = &aData[0]; // Pin the
destination array
memcpy(pDest, &data[0], tSize);
return (aData);
}