You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ld...@apache.org on 2014/07/07 21:26:54 UTC
git commit: CB-6127lisa7cordova-plugin-consolecordova-plugin-device
documentation translation: cordova-plugin-device
Repository: cordova-plugin-device
Updated Branches:
refs/heads/master df1c34f88 -> 4abfe6ec9
CB-6127lisa7cordova-plugin-consolecordova-plugin-device documentation translation: cordova-plugin-device
Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-device/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-device/commit/4abfe6ec
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-device/tree/4abfe6ec
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-device/diff/4abfe6ec
Branch: refs/heads/master
Commit: 4abfe6ec96770674844d75f2fc6514ee2af5c429
Parents: df1c34f
Author: Lisa Seacat DeLuca <ld...@us.ibm.com>
Authored: Mon Jul 7 15:26:46 2014 -0400
Committer: Lisa Seacat DeLuca <ld...@us.ibm.com>
Committed: Mon Jul 7 15:26:46 2014 -0400
----------------------------------------------------------------------
doc/es/index.md | 9 ++-
doc/ru/index.md | 214 +++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 222 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cordova-plugin-device/blob/4abfe6ec/doc/es/index.md
----------------------------------------------------------------------
diff --git a/doc/es/index.md b/doc/es/index.md
index 052f2bb..3690518 100644
--- a/doc/es/index.md
+++ b/doc/es/index.md
@@ -158,7 +158,14 @@ Los detalles de cómo se genera un UUID son determinados por el fabricante del d
### Ejemplo rápido
- / / Android: devuelve un entero de 64 bits al azar (como una cadena, otra vez!) / / el entero se genera en el primer arranque del dispositivo / / / / BlackBerry: devuelve el número PIN del dispositivo / / este es un entero único de nueve dígitos (como una cadena, aunque!) / / / / iPhone: (parafraseado de la documentación de la clase UIDevice) / / devuelve una cadena de valores hash creado a partir de múltiples hardware identifica.
+ // Android: Returns a random 64-bit integer (as a string, again!)
+ // The integer is generated on the device's first boot
+ //
+ // BlackBerry: Returns the PIN number of the device
+ // This is a nine-digit unique integer (as a string, though!)
+ //
+ // iPhone: (Paraphrased from the UIDevice Class documentation)
+ // Returns a string of hash values created from multiple hardware identifies.
/ / Está garantizado para ser único para cada dispositivo y no puede ser atado / / a la cuenta de usuario.
/ / Windows Phone 7: devuelve un hash de dispositivo + usuario actual, / / si el usuario no está definido, un guid se genera y persistirá hasta que se desinstala la aplicación / / Tizen: devuelve el dispositivo IMEI (identidad de equipo móvil internacional o IMEI es un número / / único para cada teléfono móvil GSM y UMTS.
var deviceID = device.uuid;
http://git-wip-us.apache.org/repos/asf/cordova-plugin-device/blob/4abfe6ec/doc/ru/index.md
----------------------------------------------------------------------
diff --git a/doc/ru/index.md b/doc/ru/index.md
new file mode 100644
index 0000000..d97d86b
--- /dev/null
+++ b/doc/ru/index.md
@@ -0,0 +1,214 @@
+<!---
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you 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.
+-->
+
+# org.apache.cordova.device
+
+Этот плагин определяет глобальный объект `device`, который описывает оборудование и программное обеспечение устройства. Несмотря на то что объект в глобальной области видимости, он не доступен до того момента пока не произойдет событие `deviceready`.
+
+ document.addEventListener("deviceready", onDeviceReady, false);
+ function onDeviceReady() {
+ console.log(device.cordova);
+ }
+
+
+## Установка
+
+ cordova plugin add org.apache.cordova.device
+
+
+## Свойства
+
+* device.cordova
+* device.model
+* device.name
+* device.platform
+* device.uuid
+* device.version
+
+## device.cordova
+
+Возвращает версию Cordova, работающую на устройстве.
+
+### Поддерживаемые платформы
+
+* Amazon Fire ОС
+* Android
+* BlackBerry 10
+* Firefox OS
+* iOS
+* Tizen
+* Windows Phone 7 и 8
+* Windows 8
+
+## device.model
+
+Свойство `device.model` возвращает имя устройства модели или продукта. Значение устанавливается производителем устройства и могут отличаться в разных версиях одного и того же продукта.
+
+### Поддерживаемые платформы
+
+* Android
+* BlackBerry 10
+* iOS
+* Tizen
+* Windows Phone 7 и 8
+* Windows 8
+
+### Краткий пример
+
+ // Android: Nexus One returns "Passion" (Nexus One code name)
+ // Motorola Droid returns "voles"
+ // BlackBerry: Torch 9800 returns "9800"
+ // iOS: for the iPad Mini, returns iPad2,5; iPhone 5 is iPhone 5,1. See http://theiphonewiki.com/wiki/index.php?title=Models
+ //
+ var model = device.model;
+
+
+### Особенности Android
+
+* Возвращает [имя продукта][1] , а не [имя модели][2], которое часто является производственным кодом. Например, Nexus One из них возвращает `Passion` , и Motorola Droid возвращает `voles`.
+
+ [1]: http://developer.android.com/reference/android/os/Build.html#PRODUCT
+ [2]: http://developer.android.com/reference/android/os/Build.html#MODEL
+
+### Особенности Tizen
+
+* Возвращает модель устройства, назначенного вендором, например,`TIZEN`
+
+### Особенности Windows Phone 7 и 8
+
+* Возвращает модель устройства, указанной заводом-изготовителем. Например Samsung Focus возвращает `SGH-i917`.
+
+## device.name
+
+**ПРЕДУПРЕЖДЕНИЕ**: `device.name` является устаревшим свойством начиная с версии 2.3.0. Используйте `device.model` вместо этогого свойства.
+
+## device.platform
+
+Получите имя операционной системы устройства.
+
+ var string = device.platform;
+
+
+### Поддерживаемые платформы
+
+* Android
+* BlackBerry 10
+* Firefox OS
+* iOS
+* Tizen
+* Windows Phone 7 и 8
+* Windows 8
+
+### Краткий пример
+
+ // Depending on the device, a few examples are:
+ // - "Android"
+ // - "BlackBerry 10"
+ // - "iOS"
+ // - "WinCE"
+ // - "Tizen"
+ var devicePlatform = device.platform;
+
+
+### Особенности Windows Phone 7
+
+Windows Phone 7 устройства сообщают платформу как `WinCE`.
+
+### Особенности Windows Phone 8
+
+Устройства Windows Phone 8 сообщают платформу как `Win32NT`.
+
+## device.uuid
+
+Возвращает универсальный уникального идентификатора ([UUID][3] устройства).
+
+ [3]: http://en.wikipedia.org/wiki/Universally_Unique_Identifier
+
+ var string = device.uuid;
+
+
+### Описание
+
+Подробная информация о том как UUID генерируется, определяются изготовителем устройства и являются специфическими для платформы или модели устройства.
+
+### Поддерживаемые платформы
+
+* Android
+* BlackBerry 10
+* iOS
+* Tizen
+* Windows Phone 7 и 8
+* Windows 8
+
+### Краткий пример
+
+ // Android: Возвращает случайное 64-разрядное целое число (в виде строки, опять!)
+ // целое число генерируется при первой загрузке устройства
+ //
+ // BlackBerry: Возвращает номер PIN устройства
+ // это 9 значный уникальный целочисленный (как строка, хотя!)
+ //
+ // iPhone: (Перефразировано из документации класса UIDevice)
+ // возвращает строку хэш-значения, созданные из нескольких аппаратных определяет.
+ // Это значение гарантированно является уникальным для каждого устройства и не может быть привязано
+ // к учетной записи пользователя.
+ // Windows Phone 7: Возвращает хэш устройство + текущего пользователя,
+ // если пользователь не определен, формируется guid который и будет сохраняться до тех пор, пока приложение не удалиться
+ // Tizen: возвращает IMEI устройства (Международный идентификатор мобильного оборудования или IMEI это число
+ // уникальное для каждого мобильного телефона GSM и UMTS.
+ var deviceID = device.uuid;
+
+
+### Особенности iOS
+
+На iOS `uuid` не является уникальным для устройства, но варьируется для каждого приложения, и для каждой установки. Значение меняется, если удалить и повторно установить приложение, и возможно также когда вы обновите iOS, или даже обновить приложение до следующей версии (очевидно в iOS 5.1). Значение `uuid` не является надежным.
+
+### Особенности Windows Phone 7 и 8
+
+Для Windows Phone 7 `uuid` требует разрешения `ID_CAP_IDENTITY_DEVICE` . Microsoft скорее всего скоро сделает это свойство устаревшим. Если возможность недоступна, приложение создает постоянные guid, который сохраняется на все время установки приложения на устройстве.
+
+## device.version
+
+Возвращает версию операционной системы.
+
+ var string = device.version;
+
+
+### Поддерживаемые платформы
+
+* Android 2.1 +
+* BlackBerry 10
+* iOS
+* Tizen
+* Windows Phone 7 и 8
+* Windows 8
+
+### Краткий пример
+
+ // Android: Froyo ОС будет возвращать «2.2»
+ // Eclair OS будет возвращать «2.1», «2.0.1» или «2.0»
+ // версия также может возвращать информацию об обновлении «2.1-update1»
+ //
+ // BlackBerry: Torch 9800, используя OS 6.0 будет возвращатся «6.0.0.600»
+ //
+ // iPhone: iOS 3.2 возвращает «3.2»
+ //
+ // Windows Phone 7: Возвращает номер текущей версии ОС. on Mango returns 7.10.7720
+ // Tizen: returns "TIZEN_20120425_2"
+ var deviceVersion = device.version;
\ No newline at end of file