Пример #1
0
void CMsregPacketRegistrationRequest::ReadDataFromFile(CFile& cfFile, DWORD& dwChecksum)
{
	CString csKey;
	CString csValue;

	TRY
	{
		// Read inherited data.
		CMsregPacket::ReadDataFromFile(cfFile, dwChecksum);

		// Read the product name.
		m_csProductName = ReadString(cfFile, dwChecksum);

		// Read the field count.
		DWORD dwFields = ReadDword(cfFile, dwChecksum);

		// Read Fields.
		DeleteAllFields();
		for (DWORD i = 0; i < dwFields; i++)
		{
			csKey = ReadString(cfFile, dwChecksum);
			csValue = ReadString(cfFile, dwChecksum);
			AddField(csKey, csValue);
		}
	}
	CATCH_ALL(e)
	{
		csKey.Empty();
		csValue.Empty();
		THROW_LAST();
	}
	END_CATCH_ALL
}
Пример #2
0
void CMsregPacketCatalogOrderRequest::ReadDataFromFile(CFile& cfFile, DWORD& dwChecksum)
{
	CString csKey;
	CString csValue;

	TRY
	{
		// Read inherited data.
		CMsregPacket::ReadDataFromFile(cfFile, dwChecksum);

		// Read the product name.
		m_csProductName = ReadString(cfFile, dwChecksum);

		// Read the field count.
		DWORD dwFields = ReadDword(cfFile, dwChecksum);

		// Read Fields.
		DeleteAllFields();
		for (DWORD i = 0; i < dwFields; i++)
		{
			csKey = ReadString(cfFile, dwChecksum);
			csValue = ReadString(cfFile, dwChecksum);
			AddField(csKey, csValue);
		}
		
		// Read the tax.
		m_dwTax = ReadDword(cfFile, dwChecksum);
		
		// Read the shipping.
		m_dwShipping = ReadDword(cfFile, dwChecksum);
		
		// Read the total.
		m_dwTotal = ReadDword(cfFile, dwChecksum);
		
		// Read the offer code.
		m_csOfferCode = ReadString(cfFile, dwChecksum);
		
		// Read the request code.
		m_csRequestCode = ReadString(cfFile, dwChecksum);
		
		// Read the line items.
		m_LineItems.ReadDataFromFile(cfFile, dwChecksum);
	}
	CATCH_ALL(e)
	{
		csKey.Empty();
		csValue.Empty();
		THROW_LAST();
	}
	END_CATCH_ALL
}
Пример #3
0
const DwHeaders& DwHeaders::operator = (const DwHeaders& aHeader)
{
    if (this == &aHeader) return *this;
    DwMessageComponent::operator = (aHeader);
    if (mFirstField) {
        DeleteAllFields();
    }
    if (aHeader.mFirstField) {
        CopyFields(aHeader.mFirstField);
    }
    if (mParent) {
        mParent->SetModified();
    }
    return *this;
}
Пример #4
0
DwHeaders::~DwHeaders()
{
    if (mFirstField) {
        DeleteAllFields();
    }
}
Пример #5
0
CMsregPacketCatalogOrderRequest::~CMsregPacketCatalogOrderRequest()
{
	DeleteAllFields();
	DeleteAllLineItems();
}
Пример #6
0
CMsregPacketRegistrationRequest::~CMsregPacketRegistrationRequest()
{
	DeleteAllFields();
}
Пример #7
0
CMsregPacketProductInformationRequest::~CMsregPacketProductInformationRequest()
{
	DeleteAllFields();
	DeleteAllLineItems();
}
Пример #8
0
CMsregPacketProductOrderRequest::~CMsregPacketProductOrderRequest()
{
	DeleteAllFields();
	DeleteAllLineItems();
}