Class MeteredLicense
ชื่อพื้นที่: Aspose.Zip การประกอบ: Aspose.Zip.dll (25.5.0)
ให้วิธีการในการตั้งค่ากุญแจวัด
public class MeteredLicense
Inheritance
อนุญาโตตุลาการ
object.GetType() , object.MemberwiseClone() , object.ToString() , object.Equals(object?) , object.Equals(object?, object?) , object.ReferenceEquals(object?, object?) , object.GetHashCode()
Examples
ในตัวอย่างนี้จะมีการพยายามที่จะตั้งค่ากุญแจสาธารณะและส่วนตัว
Metered metered = new Metered();
metered.SetMeteredKey("PublicKey", "PrivateKey");
Dim metered As Metered = New Metered
metered.SetMeteredKey("PublicKey", "PrivateKey")
```</ms><java>
the component jar file:
```csharp
Metered metered = new Metered();
metered.setMeteredKey("PublicKey", "PrivateKey");
```</java>
## Constructors
### <a id="Aspose_Zip_MeteredLicense__ctor"></a> MeteredLicense\(\)
```csharp
public MeteredLicense()
Methods
GetConsumptionCredit()
รับเครดิตการบริโภค
public static decimal GetConsumptionCredit()
Returns
รับคืนจํานวนจุดเครดิตที่ใช้
GetConsumptionQuantity()
รับขนาดไฟล์การบริโภค
public static decimal GetConsumptionQuantity()
Returns
กลับจํานวนไบต์ที่ใช้
ResetMeteredKey()
ลบใบอนุญาตการตั้งค่าก่อนหน้านี้
public void ResetMeteredKey()
SetMeteredKey(รั้ว, รั้ว)
เก็บคีย์สาธารณะและส่วนตัว
public void SetMeteredKey(string publicKey, string privateKey)
Parameters
publicKey
string
คีย์สาธารณะ
privateKey
string
คีย์ส่วนตัว
Remarks
หากคุณซื้อใบอนุญาตวัด API นี้ควรจะถูกเรียกใช้ในโปรแกรมเริ่มต้น โดยปกติแล้วนี่เป็นเพียงพออย่างไรก็ตามหากผู้วัดไม่สามารถอัปโหลดข้อมูลการบริโภคได้ภายใน 24 ชั่วโมงใบอนุญาตจะถูกตั้งค่าไว้ในสถานะการประเมิน เพื่อหลีกเลี่ยงกรณีดังกล่าวคุณควรตรวจสอบสถานะการประเมินอย่างเป็นประจํา หากเป็นสถานะการประเมินโทรหา API นี้อีกครั้ง