Interface IStorage
Interface IStorage
名称: Aspose.Html.Dom 编辑: Aspose.HTML.dll (25.4.0)
此 Web Storage API 接口可访问特定域的会议或本地存储。查看 Web Storage 规格: https://html.spec.whatwg.org/multipage/webstorage.html#webstorage
[ComVisible(true)]
[DOMObject]
[DOMName("Storage")]
public interface IStorage
Properties
Length
返回关键/值对的数量。
[DOMName("length")]
long Length { get; }
财产价值
Methods
Clear()
删除所有关键/值对,如果有。
[DOMName("clear")]
void Clear()
GetItem(线条)
返回与所提供的密钥相关的当前值或零,如果所提供的密钥不存在。
[DOMName("getItem")]
string GetItem(string key)
Parameters
key
string
关键链条。
Returns
元素值链。
Key(长久)
返回 nth 密钥的名称,或者 null 如果 n 比或相当于关键/值对的数量。
[DOMName("key")]
string Key(long n)
Parameters
n
long
存储物品数量。
Returns
关键链条
RemoveItem(线条)
删除与此密钥的关键/值对,如果与此密钥的关键/值对存在。
[DOMName("removeItem")]
void RemoveItem(string key)
Parameters
key
string
关键链条。
SetItem(字符串, string)
将按密钥识别的对值设置为值,创建一个新的密钥/值对,如果此前没有对密钥存在。
[DOMName("setItem")]
void SetItem(string key, string value)
Parameters
key
string
关键链条。
value
string
元素值链。