Zhi Dou | eb74489 | 2023-05-10 04:02:33 +0000 | [diff] [blame^] | 1 | package com.android.aconfig; |
2 | {{ if readwrite }} | ||||
3 | import android.provider.DeviceConfig; | ||||
4 | {{ endif }} | ||||
5 | public final class {namespace} \{ | ||||
6 | {{ for item in class_elements}} | ||||
7 | public static boolean {item.method_name}() \{ | ||||
8 | {{ if item.readwrite- }} | ||||
9 | return DeviceConfig.getBoolean( | ||||
10 | "{namespace}", | ||||
11 | "{item.feature_name}__{item.flag_name}", | ||||
12 | {item.default_value} | ||||
13 | ); | ||||
14 | {{ -else- }} | ||||
15 | return {item.default_value}; | ||||
16 | {{ -endif }} | ||||
17 | } | ||||
18 | {{ endfor }} | ||||
19 | } |