Partilhar via


AdministrationMetadataCatalog.ExportPackage Method (String, PackageContents, String)

Returns an XML representation of the metadata model using the model name, the package contents, and the setting identifier.

Namespace:  Microsoft.SharePoint.BusinessData.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Public Function ExportPackage ( _
    modelName As String, _
    packageContents As PackageContents, _
    settingId As String _
) As String
'Usage
Dim instance As AdministrationMetadataCatalog
Dim modelName As String
Dim packageContents As PackageContents
Dim settingId As String
Dim returnValue As String

returnValue = instance.ExportPackage(modelName, _
    packageContents, settingId)
public string ExportPackage(
    string modelName,
    PackageContents packageContents,
    string settingId
)

Parameters

  • settingId
    Type: System.String

    The identifier of a partition in the Metadata Store where to read properties, localized names, and access control entries.

Return Value

Type: System.String
The XML representation of the metadata model.

Exceptions

Exception Condition
ArgumentException

The modelName parameter is a null reference (Nothing in Visual Basic) or empty, or the packageContents parameter has PackageContents.InlineProxies set and PackageContents.Model unset.

Remarks

If packageContents is set to PackageContents.Model, the method returns an XML representation of all the metadata object contained in the metadata model, along with their properties, localized names and access control entries. Otherwise, the method returns an XML representation of only the localized names, properties, and access control entries that correspond to the metadata objects in the model.

See Also

Reference

AdministrationMetadataCatalog Class

AdministrationMetadataCatalog Members

ExportPackage Overload

Microsoft.SharePoint.BusinessData.Administration Namespace