@ohos.deviceInfo.d.ts 5.4 KB
Newer Older
M
Mupceet 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245
/*
 * Copyright (c) 2021 Huawei Device Co., Ltd.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

/**
 * A static class pertaining to the product information.
 *
 * @devices phone, tablet
 * @since 6
 * @Syscap SystemCapability.Startup.SysInfo
 */
declare namespace deviceInfo {
     /**
     * Obtains the device type represented by a string,
     * which can be {@code phone} (or {@code default} for phones), {@code wearable}, {@code liteWearable},
     * {@code tablet}, {@code tv}, {@code car}, or {@code smartVision}.
     *
     * @since 6
     */
    const deviceType: string;

    /**
     * Obtains the device manufacturer represented by a string.
     *
     * @since 6
     */
    const manufacture: string;

    /**
     * Obtains the device brand represented by a string.
     *
     * @since 6
     */
    const brand: string;

    /**
     * Obtains the external product series represented by a string.
     *
     * @since 6
     */
    const marketName: string;

    /**
     * Obtains the product series represented by a string.
     *
     * @since 6
     */
    const productSeries: string;

    /**
     * Obtains the product model represented by a string.
     *
     * @since 6
     */
    const productModel: string;

    /**
     * Obtains the software model represented by a string.
     *
     * @since 6
     */
    const softwareModel: string;

    /**
     * Obtains the hardware model represented by a string.
     *
     * @since 6
     */
    const hardwareModel: string;

    /**
     * Obtains the hardware profile represented by a string.
     *
     * @since 6
     */
    const hardwareProfile: string;

    /**
     * Obtains the device serial number represented by a string.
     *
     * @since 6
     */
    const serial: string;

    /**
     * Obtains the bootloader version number represented by a string.
     *
     * @since 6
     */
    const bootloaderVersion: string;

    /**
     * Obtains the application binary interface (Abi) list represented by a string.
     *
     * @since 6
     */
    const abiList: string;

    /**
     * Obtains the security patch level represented by a string.
     *
     * @since 6
     */
    const securityPatchTag: string;

    /**
     * Obtains the product version represented by a string.
     *
     * @since 6
     */
    const displayVersion: string;

    /**
     * Obtains the incremental version represented by a string.
     *
     * @since 6
     */
    const incrementalVersion: string;

    /**
     * Obtains the OS release type represented by a string.
     *
     * <p>The OS release category can be {@code Release}, {@code Beta}, or {@code Canary}.
     * The specific release type may be {@code Release}, {@code Beta1}, or others alike.
     *
     * @since 6
     */
    const osReleaseType: string;

    /**
     * Obtains the OS version represented by a string.
     *
     * @since 6
     */
    const osFullName: string;

    /**
     * Obtains the major (M) version number, which increases with any updates to the overall architecture.
     * <p>The M version number monotonically increases from 1 to 99.
     *
     * @since 6
     */
    const majorVersion: number;

    /**
     * Obtains the senior (S) version number, which increases with any updates to the partial
     * architecture or major features.
     * <p>The S version number monotonically increases from 0 to 99.
     *
     * @since 6
     */
    const seniorVersion: number;

    /**
     * Obtains the feature (F) version number, which increases with any planned new features.
     * <p>The F version number monotonically increases from 0 or 1 to 99.
     *
     * @since 6
     */
    const featureVersion: number;

    /**
     * Obtains the build (B) version number, which increases with each new development build.
     * <p>The B version number monotonically increases from 0 or 1 to 999.
     *
     * @since 6
     */
    const buildVersion: number;

    /**
     * Obtains the SDK API version number.
     *
     * @since 6
     */
    const sdkApiVersion: number;

    /**
     * Obtains the first API version number.
     *
     * @since 6
     */
    const firstApiVersion: number;

    /**
     * Obtains the version ID by a string.
     *
     * @since 6
     */
    const versionId: string;

    /**
     * Obtains the build types of the same baseline code.
     *
     * @since 6
     */
    const buildType: string;

    /**
     * Obtains the different build user of the same baseline code.
     *
     * @since 6
     */
    const buildUser: string;

    /**
     * Obtains the different build host of the same baseline code.
     *
     * @since 6
     */
    const buildHost: string;

    /**
     * Obtains the build time.
     *
     * @since 6
     */
    const buildTime: string;

    /**
     * Obtains the version hash.
     *
     * @since 6
     */
    const buildRootHash: string;

    /**
     * Obtains the device udid.
     *
     * @since 7
     */
    const udid: string;
}

export default deviceInfo;