SoapYearMonth Class
Wraps an XSD gYearMonth type.
Assembly: mscorlib (in mscorlib.dll)
| Name | Description | |
|---|---|---|
![]() | SoapYearMonth() | Initializes a new instance of the SoapYearMonth class. |
![]() | SoapYearMonth(DateTime) | Initializes a new instance of the SoapYearMonth class with a specified DateTime object. |
![]() | SoapYearMonth(DateTime, Int32) |
| Name | Description | |
|---|---|---|
![]() | Equals(Object^) | Determines whether the specified object is equal to the current object.(Inherited from Object.) |
![]() | GetHashCode() | Serves as the default hash function. (Inherited from Object.) |
![]() | GetType() | |
![]() | GetXsdType() | Returns the XML Schema definition language (XSD) of the current SOAP type. |
![]() ![]() | Parse(String^) | Converts the specified String into a SoapYearMonth object. |
![]() | ToString() | Returns a Value as a String.(Overrides Object::ToString().) |
For more information about XSD data types, see "XML Data Types Reference" in the MSDN Library at http://msdn.microsoft.com/library.
The following code example demonstrates using the SoapYearMonth class to wrap the XSD gYearMonth type.
using namespace System; using namespace System::Runtime::Remoting::Metadata::W3cXsd2001; int main() { // Parse an XSD gYearMonth to create a SoapYearMonth object. // The timezone of this object is -08:00. String^ xsdYearMonth = "2003-11-08:00"; SoapYearMonth^ yearMonth = SoapYearMonth::Parse( xsdYearMonth ); // Display the yearMonth in XSD format. Console::WriteLine( "The yearMonth in XSD format is {0}.", yearMonth ); // Display the XSD type string of this particular SoapYearMonth object. Console::WriteLine( "The XSD type of the SoapYearMonth instance is {0}.", yearMonth->GetXsdType() ); // Display the value of the SoapYearMonth object. Console::WriteLine( "The value of the SoapYearMonth instance is {0}.", yearMonth->Value ); // Display the sign of the SoapYearMonth object. Console::WriteLine( "The sign of the SoapYearMonth instance is {0}.", yearMonth->Sign ); // Display the XSD type string of the SoapYearMonth class. Console::WriteLine( "The XSD type of the class SoapYearMonth is {0}.", SoapYearMonth::XsdType ); }
Available since 1.1
Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.


