SoapTime Class
Wraps an XSD time type.
Assembly: mscorlib (in mscorlib.dll)
The following code example demonstrates using the SoapTime class to wrap an XSD time type.
using namespace System; using namespace System::Runtime::Remoting::Metadata::W3cXsd2001; int main() { // Parse an XSD gTime to create a SoapTime object. // The timezone of this object is the current timezone. String^ xsdTime = "12:13:14.123Z"; SoapTime^ time = SoapTime::Parse( xsdTime ); // Display the time in XSD format. Console::WriteLine( "The time in XSD format is {0}.", time ); // Display the XSD type string of this particular SoapTime object. Console::WriteLine( "The XSD type of the SoapTime instance is {0}.", time->GetXsdType() ); // Display the value of the SoapTime object. Console::WriteLine( "The value of the SoapTime instance is {0}.", time->Value ); // Display the XSD type string of the SoapTime class. Console::WriteLine( "The XSD type of the class SoapTime is {0}.", SoapTime::XsdType ); }
#using <mscorlib.dll>
using namespace System;
using namespace System::Runtime::Remoting::Metadata::W3cXsd2001;
int main()
{
// Parse an XSD gTime to create a SoapTime object.
// The timezone of this object is the current timezone.
String* xsdTime = S"12:13:14.123Z";
SoapTime* time = SoapTime::Parse(xsdTime);
// Display the time in XSD format.
Console::WriteLine(S"The time in XSD format is {0}.",
time);
// Display the XSD type string of this particular SoapTime object.
Console::WriteLine(S"The XSD type of the SoapTime instance is {0}.",
time->GetXsdType());
// Display the value of the SoapTime object.
Console::WriteLine(S"The value of the SoapTime instance is {0}.",
__box(time->Value));
// Display the XSD type string of the SoapTime class.
Console::WriteLine(S"The XSD type of the class SoapTime is {0}.",
SoapTime::XsdType);
}
Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98
The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Community Additions
Show: