Public Types | Public Member Functions | Static Public Member Functions | List of all members
XmlFragmentList Struct Reference

Class used to process list of XML Fragments. More...

#include <XMLFragment.h>

Inheritance diagram for XmlFragmentList:
RefCountedBase RefCounted< IRefCounted > IRefCounted

Public Types

typedef bvector
< XmlFragmentPtr >
::const_iterator 
const_iterator
 
typedef const_iterator iterator
 only const iteration is possible More...
 

Public Member Functions

DGNPLATFORM_EXPORT bvector
< XmlFragmentPtr >::iterator 
begin ()
 Returns the beginning of an iteration over the XMLFragments within this XmlFragmentList. More...
 
DGNPLATFORM_EXPORT bvector
< XmlFragmentPtr >::iterator 
end ()
 Returns the end of the an iteration over the XMLFragments within this XmlFragmentList. More...
 
DGNPLATFORM_EXPORT StatusInt Append (XmlFragment const *xmlFragment)
 Appends an XML Fragment List to an XML Fragment List. More...
 
DGNPLATFORM_EXPORT StatusInt Prepend (XmlFragment const *xmlFragment)
 Prepend an XML Fragment List to the head of an XML Fragment List. More...
 
DGNPLATFORM_EXPORT StatusInt Remove (size_t index)
 Remove an XML Fragment from an XML Fragment List. More...
 
DGNPLATFORM_EXPORT size_t GetCount ()
 Get the number of XML Fragments in a XML Fragment List. More...
 
DGNPLATFORM_EXPORT XmlFragmentPtr GetFragmentAtIndex (size_t index)
 Get specified XML Fragment from an XML Fragment List. More...
 
DGNPLATFORM_EXPORT StatusInt AttachToElement (EditElementHandleR eeh)
 Attach all XML Fragments in the list as linkages to specified element. More...
 
- Public Member Functions inherited from RefCounted< IRefCounted >
void * operator new (size_t size)
 
void operator delete (void *rawMemory, size_t size)
 
UInt32 AddRef () const
 
UInt32 Release () const
 
 RefCounted ()
 
 RefCounted (RefCounted const &rhs)
 
RefCountedoperator= (RefCounted const &rhs)
 
UInt32 GetRefCount () const
 

Static Public Member Functions

static DGNPLATFORM_EXPORT
XmlFragmentListPtr 
ConstructFromFragment (XmlFragment const *xmlFragment)
 Constructs an XML Fragment List containing a single XML Fragment. More...
 
static DGNPLATFORM_EXPORT
XmlFragmentListPtr 
Construct (WChar *pText, WChar *pSchemaURN, UShort appID, UShort appType)
 Constructs an XML Fragment List containing a single XML Fragment. More...
 
static DGNPLATFORM_EXPORT
XmlFragmentListPtr 
ConstructFromBuffer (byte *pBuffer, UInt32 ulBufferSize, UShort appId=0, UShort appType=0)
 Constructs an XML Fragment List and populate it with an XML Fragment created from the stream buffer data. More...
 
static DGNPLATFORM_EXPORT
XmlFragmentListPtr 
ExtractFromElement (ElementHandleCR eh, const UShort *pAppID=NULL, const UShort *pAppType=NULL)
 Constructs an XML Fragment List by containing all XML Fragments from all linkages matching the specifiec AppId and AppType. More...
 

Additional Inherited Members

- Protected Member Functions inherited from RefCounted< IRefCounted >
virtual ~RefCounted ()
 
- Protected Member Functions inherited from IRefCounted
virtual ~IRefCounted ()
 
void * operator new (size_t size)
 
void operator delete (void *rawMemory, size_t size)
 

Detailed Description

Class used to process list of XML Fragments.

See also
XmlFragment
Remarks
Required library : DgnPlatform<ApiNumber>.lib i.e. DgnPlatform5.lib

Member Typedef Documentation

typedef bvector<XmlFragmentPtr>::const_iterator const_iterator

only const iteration is possible

Member Function Documentation

DGNPLATFORM_EXPORT StatusInt Append ( XmlFragment const *  xmlFragment)

Appends an XML Fragment List to an XML Fragment List.

Parameters
[in]xmlFragmentXML Fragment to append.
Returns
normally SUCCESS; MDLERR_BADARG if xmlFragment is invalid

Attach all XML Fragments in the list as linkages to specified element.

Parameters
[in]eehElement to receive linkages
See also
ExtractFromElement
DGNPLATFORM_EXPORT bvector<XmlFragmentPtr>::iterator begin ( )

Returns the beginning of an iteration over the XMLFragments within this XmlFragmentList.

static DGNPLATFORM_EXPORT XmlFragmentListPtr Construct ( WChar pText,
WChar pSchemaURN,
UShort  appID,
UShort  appType 
)
static

Constructs an XML Fragment List containing a single XML Fragment.

Parameters
[in]pTextXML text to set (or NULL).
[in]pSchemaURNSchema URN to set (or NULL).
[in]appIDThe ID of the "app" to which this XmlFragment belongs. The app identifier is a Bentley assigned application identifier. (typically an application's LinkageID).
[in]appTypeThe type of this XmlFragment within the "app" to which it belongs. The app type is an application assigned value which uniquely identifies the XML Fragment within the application's app.
Returns
XmlFragmentListPtr, use IsValid() test to see if the method was successful.
static DGNPLATFORM_EXPORT XmlFragmentListPtr ConstructFromBuffer ( byte pBuffer,
UInt32  ulBufferSize,
UShort  appId = 0,
UShort  appType = 0 
)
static

Constructs an XML Fragment List and populate it with an XML Fragment created from the stream buffer data.

Parameters
[in]pBufferA byte buffer containing the XML fragment data
[in]ulBufferSizeThe size of data in buffer
[in]appIdThe ID of the "app" to which this XmlFragment belongs
[in]appTypeThe type of this XmlFragment within the "app" to which it belongs
static DGNPLATFORM_EXPORT XmlFragmentListPtr ConstructFromFragment ( XmlFragment const *  xmlFragment)
static

Constructs an XML Fragment List containing a single XML Fragment.

Parameters
[in]xmlFragmentXML fragment to be used as the fist entry in the list.
Returns
XmlFragmentListPtr, use IsValid() test to see if the method was successful.
DGNPLATFORM_EXPORT bvector<XmlFragmentPtr>::iterator end ( )

Returns the end of the an iteration over the XMLFragments within this XmlFragmentList.

static DGNPLATFORM_EXPORT XmlFragmentListPtr ExtractFromElement ( ElementHandleCR  eh,
const UShort pAppID = NULL,
const UShort pAppType = NULL 
)
static

Constructs an XML Fragment List by containing all XML Fragments from all linkages matching the specifiec AppId and AppType.

Parameters
[in]ehElement that contains XML Fragment linkages
[in]pAppIDThe AppID of the linkage to find. May be NULL if pAppType is also NULL, which means find any XML Fragment linkage.
[in]pAppTypeThe AppType of the linkage to find. If NULL only the pAppID test must be satisfied for a linkage to be found.
DGNPLATFORM_EXPORT size_t GetCount ( )

Get the number of XML Fragments in a XML Fragment List.

DGNPLATFORM_EXPORT XmlFragmentPtr GetFragmentAtIndex ( size_t  index)

Get specified XML Fragment from an XML Fragment List.

Parameters
[in]indexIndex of fragment in list.
Returns
a valid XmlFragmentPtr if index is valid. If not XmlFragment.IsValid() will return false.
DGNPLATFORM_EXPORT StatusInt Prepend ( XmlFragment const *  xmlFragment)

Prepend an XML Fragment List to the head of an XML Fragment List.

Parameters
[in]xmlFragmentXML Fragment to prepend.
Returns
normally SUCCESS; MDLERR_BADARG if xmlFragment is invalid
DGNPLATFORM_EXPORT StatusInt Remove ( size_t  index)

Remove an XML Fragment from an XML Fragment List.

Parameters
[in]indexIndex of fragment in list.
Returns
normally SUCCESS; MDLERR_BADARG if indexOfFragment is invalid

The documentation for this struct was generated from the following file:

Copyright © 2017 Bentley Systems, Incorporated. All rights reserved.