Class XmpMetadata
Namespace: Aspose.Page.EPS.XMP
Assembly: Aspose.Page.dll (25.1.2)
提供对XMP元数据流的访问。
public sealed class XmpMetadata : IDictionary<string, xmpvalue="">, ICollection<keyvaluepair<string, xmpvalue="">>, IEnumerable<keyvaluepair<string, xmpvalue="">>, IEnumerable
继承
实现
IDictionary<string, xmpvalue="">, ICollection<keyvaluepair<string, xmpvalue="">>, IEnumerable<keyvaluepair<string, xmpvalue="">>, IEnumerable
继承的成员
object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
属性
Count
获取集合中元素的数量。
public int Count { get; }
属性值
IsFixedSize
检查集合是否具有固定大小。
public bool IsFixedSize { get; }
属性值
IsReadOnly
检查集合是否为只读。
public bool IsReadOnly { get; }
属性值
IsSynchronized
检查集合是否已同步。
public bool IsSynchronized { get; }
属性值
Keys
获取元数据键的集合。
public ICollection<string> Keys { get; }
属性值
ICollection<string>
NamespaceManager
获取命名空间管理器。
public XmlNamespaceManager NamespaceManager { get; }
属性值
XmlNamespaceManager
SyncRoot
获取集合同步对象。
public object SyncRoot { get; }
属性值
Values
获取元数据中的值。
public ICollection<xmpvalue> Values { get; }
属性值
ICollection<XmpValue>
this[string]
获取或设置元数据中的数据。
public XmpValue this[string key] { get; set; }
属性值
方法
Add(string, XmpValue)
向元数据添加值。
public void Add(string key, XmpValue value)
参数
key
string
要添加的键。
value
XmpValue
将要添加的值。
Add(string, object)
向元数据添加值。
public void Add(string key, object value)
参数
key
string
要添加的键。
value
object
将要添加的值。
Add(KeyValuePair<string, xmpvalue="">)
将键值对添加到字典中。
public void Add(KeyValuePair<string, xmpvalue=""> item)
参数
item
KeyValuePair<string, XmpValue>
要添加的项。
AddArrayItem(string, XmpValue)
将值添加到数组中。值将添加到数组的末尾。
public void AddArrayItem(string arrayKey, XmpValue value)
参数
arrayKey
string
要在字典中搜索的数组的键。
value
XmpValue
要添加到数组中的值。
AddArrayItem(string, int, XmpValue)
通过指定索引将值添加到数组中。
public void AddArrayItem(string arrayKey, int index, XmpValue value)
参数
arrayKey
string
要在字典中搜索的数组的键。
index
int
数组中新值的索引。
value
XmpValue
要添加到数组中的值。
AddNamedValue(string, string, XmpValue)
将命名值添加到结构中。
public void AddNamedValue(string structureKey, string valueKey, XmpValue value)
参数
structureKey
string
要在字典中搜索的结构的键。
valueKey
string
要添加到结构中的值的名称。
value
XmpValue
要添加到结构中的值。
Clear()
清除元数据。
public void Clear()
Contains(string)
检查键是否包含在元数据中。
public bool Contains(string key)
参数
key
string
要查找的条目的键。
返回
如果键包含在元数据中,则为真。
Contains(KeyValuePair<string, xmpvalue="">)
检查指定的键值对是否包含在字典中。
public bool Contains(KeyValuePair<string, xmpvalue=""> item)
参数
item
KeyValuePair<string, XmpValue>
键值对。
返回
如果找到此对,则为真。
ContainsKey(string)
确定该字典是否包含指定的键。
public bool ContainsKey(string key)
参数
key
string
要在字典中搜索的键。
返回
如果找到键,则为真。
CopyTo(KeyValuePair<string, xmpvalue="">[], int)
将集合的元素复制到数组中。
public void CopyTo(KeyValuePair<string, xmpvalue="">[] array, int index)
参数
array
KeyValuePair<string, XmpValue>[]
目标数组。
index
int
起始索引。
GetEnumerator()
返回字典枚举器。
public IEnumerator<keyvaluepair<string, xmpvalue="">> GetEnumerator()
返回
IEnumerator<KeyValuePair<string, XmpValue>>
枚举器。
GetNamespaceUriByPrefix(string)
通过前缀返回命名空间URI。
public string GetNamespaceUriByPrefix(string prefix)
参数
prefix
string
前缀的值。
返回
命名空间URI的值。
GetPrefixByNamespaceUri(string)
通过命名空间URI返回前缀。
public string GetPrefixByNamespaceUri(string namespaceUri)
参数
namespaceUri
string
命名空间URI。
返回
前缀的值。
RegisterNamespaceUri(string, string)
注册命名空间URI。
public void RegisterNamespaceUri(string prefix, string namespaceUri)
参数
prefix
string
前缀的值。
namespaceUri
string
命名空间URI的值。
RegisterNamespaceUri(string, string, string)
注册命名空间URI。
public void RegisterNamespaceUri(string prefix, string namespaceUri, string schemaDescription)
参数
prefix
string
前缀的值。
namespaceUri
string
命名空间URI的值。
schemaDescription
string
模式描述的值。
Remove(string)
从元数据中移除条目。
public bool Remove(string key)
参数
key
string
要移除的条目的键。
返回
如果键被移除,则为真;否则为假。
Remove(KeyValuePair<string, xmpvalue="">)
从集合中移除键/值对。
public bool Remove(KeyValuePair<string, xmpvalue=""> item)
参数
item
KeyValuePair<string, XmpValue>
要移除的键/值对。
返回
如果找到并移除该对,则为真。
SetArrayItem(string, int, XmpValue)
在数组中设置值。先前的值将被新值替换。
public void SetArrayItem(string arrayKey, int index, XmpValue value)
参数
arrayKey
string
要在字典中搜索的数组的键。
index
int
数组中新值的索引。
value
XmpValue
要在数组中设置的值。
SetNamedValue(string, string, XmpValue)
在结构中设置命名值。如果先前的命名值已存在,则将被新值替换。
public void SetNamedValue(string structureKey, string valueKey, XmpValue value)
参数
structureKey
string
要在字典中搜索的结构的键。
valueKey
string
要设置到结构中的值的名称。
value
XmpValue
要设置到结构中的值。
TryGetValue(string, out XmpValue)
尝试在字典中查找键,并在找到时检索值。
public bool TryGetValue(string key, out XmpValue value)
参数
key
string
要在字典中搜索的键。
value
XmpValue
检索的值。
返回
如果找到键,则为真。