Extension function to create a text message from an object. The object must be serializable to XML.

Namespace:  Apache.NMS
Assembly:  Apache.NMS (in Apache.NMS.dll)

Syntax

Visual Basic
<ExtensionAttribute> _
Public Shared Function CreateXmlMessage ( _
	session As ISession, _
	obj As Object _
) As ITextMessage
C#
public static ITextMessage CreateXmlMessage(
	this ISession session,
	Object obj
)
Visual C++
[ExtensionAttribute]
public:
static ITextMessage^ CreateXmlMessage(
	ISession^ session, 
	Object^ obj
)
JavaScript
Apache.NMS.SessionExtensions.createXmlMessage = function(session, obj);

Parameters

session
Type: Apache.NMS..::..ISession
obj
Type: System..::..Object

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type ISession. When you use instance method syntax to call this method, omit the first parameter. For more information, see or .

See Also