Searched refs:Persistence (Results 1 – 5 of 5) sorted by relevance
29 import com.android.libraries.pcc.chronicle.api.policy.capabilities.Capability.Persistence45 assertThat(Capabilities(Persistence.ON_DISK).isEmpty).isFalse() in testCapabilitiesEmpty()46 assertThat(Capabilities(listOf(Persistence.ON_DISK)).isEmpty).isFalse() in testCapabilitiesEmpty()59 assertThat(persistent.persistence).isEqualTo(Persistence.ON_DISK) in testCapabilitiesFromAnnotationsPersistent()82 assertThat(persistentAndTtl30d.persistence).isEqualTo(Persistence.ON_DISK) in testCapabilitiesFromAnnotationsPersistentAndTtl()105 assertThat(tiedToRuntime.persistence).isEqualTo(Persistence.IN_MEMORY) in testCapabilitiesFromAnnotationsTiedToRuntimeAndTtl()116 Persistence.ON_DISK.toRange(), in testCapabilitiesContains()121 assertThat(capabilities.contains(Persistence.ON_DISK)).isTrue() in testCapabilitiesContains()122 assertThat(capabilities.contains(Persistence.UNRESTRICTED)).isFalse() in testCapabilitiesContains()123 assertThat(capabilities.contains(Persistence.IN_MEMORY)).isFalse() in testCapabilitiesContains()[all …]
33 import com.android.libraries.pcc.chronicle.api.policy.capabilities.Capability.Persistence110 Capabilities(listOf(Persistence.ON_DISK, Encryption(true), Ttl.Minutes(120))) in testPolicyTargetToCapabilities()115 … capabilities[1].isEquivalent(Capabilities(listOf(Persistence.IN_MEMORY, Ttl.Minutes(120)))) in testPolicyTargetToCapabilities()
46 is Persistence -> compare(other as Persistence) in isLessStrict()75 data class Persistence(val kind: Kind) : Capability(TAG) { in toRange() dataClass78 fun compare(other: Persistence): Comparison { in toRange()88 val UNRESTRICTED = Persistence(Kind.Unrestricted) in toRange()89 val ON_DISK = Persistence(Kind.OnDisk) in toRange()90 val IN_MEMORY = Persistence(Kind.InMemory) in toRange()91 val NONE = Persistence(Kind.None) in toRange()93 val ANY = Range(Persistence.UNRESTRICTED, Persistence.NONE) in toRange()95 fun fromAnnotations(annotations: List<Annotation>): Persistence? { in toRange()119 1 -> Persistence(kinds.elementAt(0)) in toRange()
38 val persistence: Capability.Persistence? in <lambda>()39 get() = getCapability<Capability.Persistence>() in <lambda>()91 Capability.Persistence.fromAnnotations(annotations)?.let { in <lambda>()
66 StorageMedium.DISK -> Capability.Persistence.ON_DISK in toCapabilities()67 StorageMedium.RAM -> Capability.Persistence.IN_MEMORY in toCapabilities()