API Reference
Class
BenchmarkPolicySerializer
Reads, writes, hashes, and validates governed benchmark policies.
Inheritance
- Object
- BenchmarkPolicySerializer
Methods
public static String CalculateHash(BenchmarkPolicySet policy) #Returns:
StringCalculates the canonical content hash while excluding the mutable hash property.
Parameters
- policy TestimoX.Benchmarks.Policy.BenchmarkPolicySet
public static BenchmarkPolicySet Deserialize(String json, String sourceName = null) #Returns:
BenchmarkPolicySetDeserializes and integrity-verifies a governed policy from JSON.
Parameters
- json System.String
- sourceName System.String = null
public static BenchmarkPolicySet Load(String path) #Returns:
BenchmarkPolicySetLoads and integrity-verifies a policy from disk.
Parameters
- path System.String
public static Void Save(BenchmarkPolicySet policy, String path) #Returns:
VoidValidates, hashes, and atomically writes a policy.
Parameters
- policy TestimoX.Benchmarks.Policy.BenchmarkPolicySet
- path System.String
public static String Serialize(BenchmarkPolicySet policy) #Returns:
StringSerializes a governed policy after refreshing its integrity hash.
Parameters
- policy TestimoX.Benchmarks.Policy.BenchmarkPolicySet
public static Void Validate(BenchmarkPolicySet policy, Boolean verifyHash) #Returns:
VoidValidates governance fields and optionally verifies integrity.
Parameters
- policy TestimoX.Benchmarks.Policy.BenchmarkPolicySet
- verifyHash System.Boolean