目录搜索
androidManifestManifest.permissionManifest.permission_groupandroid.accessibilityserviceAccessibilityServiceandroid.accountsAccountandroid.appNotificationManagerandroid.bluetoothBluetoothAdapterBluetoothClassBluetoothClass.DeviceBluetoothClass.Device.MajorBluetoothClass.ServiceBluetoothDeviceBluetoothServerSocketBluetoothSocketandroid.contentSharedPreferencesandroid.database.sqliteSQLiteCursorDriverSQLiteOpenHelperandroid.graphicsBitmapandroid.locationLocationListenerGeocoderGpsStatusGpsStatus.ListenerGpsStatus.NmeaListenerGpsSatelliteandroid.mediaAudioFormatAsyncPlayerAudioRecordAudioRecord.OnRecordPositionUpdateListenerThumbnailUtilsAudioManagerandroid.netTrafficStatsMailToLocalSocketandroid.osAsyncTaskAsyncTask.StatusCountDownTimerMessageMessageQueueHandlerThreadandroid.textHtmlandroid.utilJsonWriterandroid.viewContextMenuContextMenu.ContextMenuInfoDisplayViewManagerViewViewStubViewTreeObserverViewParentWindowManagerGestureDetectorGravityMenuInflaterScaleGestureDetectorSoundEffectConstantsandroid.view.inputmethodInputConnectionInputMethodInputMethodSessionBaseInputConnectionInputMethodManagerandroid.widgetAbsListViewAbsListView.LayoutParamsAbsListView.OnScrollListenerAbsListView.RecyclerListenerAbsoluteLayoutAbsoluteLayout.LayoutParamsAbsSeekBarAbsSpinnerAdapterViewAdapterView.AdapterContextMenuInfoAdapterView.OnItemLongClickListenerAdapterView.OnItemSelectedListenerAdapterView.OnItemClickListenerAnalogClockBaseAdapterBaseExpandableListAdapterButtonCheckBoxCheckedTextViewCheckableChronometerChronometer.OnChronometerTickListenerCompoundButtonCompoundButton.OnCheckedChangeListenerCursorAdapterCursorTreeAdapterDatePickerDatePicker.OnDateChangedListenerDialerFilterDigitalClockEditTextFilterFilter.FilterListenerFilter.FilterResultsExpandableListAdapterExpandableListView.OnChildClickListenerExpandableListView.OnGroupClickListenerExpandableListView.OnGroupCollapseListenerExpandableListView.OnGroupExpandListenerFilterableGalleryGallery.LayoutParamsGridViewGridLayoutGridLayout.AlignmentRadioGroupImageViewImageView.ScaleTypeHorizontalScrollViewImageButtonImageSwitcherFilterQueryProviderListAdapterListViewMediaControllerMultiAutoCompleteTextViewMultiAutoCompleteTextView.CommaTokenizerMultiAutoCompleteTextView.TokenizerQuickContactBadgeRadioButtonRatingBarRatingBar.OnRatingBarChangeListenerRelativeLayoutRemoteViewsResourceCursorAdapterResourceCursorTreeAdapterScrollerScrollViewSearchViewSearchView.OnCloseListenerSearchView.OnQueryTextListenerSearchView.OnSuggestionListenerSeekBarSeekBar.OnSeekBarChangeListenerSimpleAdapterSimpleAdapter.ViewBinderSimpleCursorAdapterSimpleCursorAdapter.CursorToStringConverterSimpleCursorAdapter.ViewBinderSimpleCursorTreeAdapterSimpleCursorTreeAdapter.ViewBinderSimpleExpandableListAdapterSlidingDrawerSlidingDrawer.OnDrawerCloseListenerSlidingDrawer.OnDrawerOpenListenerSlidingDrawer.OnDrawerScrollListenerSpinnerSpinnerAdapterWrapperListAdapterTabHostTabHost.TabSpecTextViewTimePickerTimePicker.OnTimeChangedListenerToastTableLayoutTableLayout.LayoutParamsTableRowTableRow.LayoutParamsTabWidgetTextSwitcherToggleButtonTwoLineListItemVideoViewViewAnimatorViewFlipperViewSwitcherViewSwitcher.ViewFactoryZoomButtonsControllerZoomButtonsController.OnZoomListenerZoomButtonZoomControlsdalvik.systemDexFile
文字


GpsStatus

版本:Android 3.2 r1

结构

继承关系

public final class GpsStatus extends Object

java.lang.Object

android.location.GpsStatus

类概述

此类用于表述GPS引擎的当前状态,此类需要和GpsStatus.Listener接口结合使用。

常量

int GPS_EVENT_FIRST_FIX

GPS系统模块接收到第一次GPS定位信息之后发送此事件码。调用getTimeToFirstFix()方法获取自GPS系统模块被开启至第一次定位所消耗的时间。

常量值:3(0x00000003)

int GPS_EVENT_SATELLITE_STATUS

周期性发送GPS卫星状态的事件码。调用getSatellites()方法获取每一颗定位卫星的各种状态。(译者注:此事件码需在获取到卫星状态之后,才会发送。在没有搜索到卫星的时候,不会发送此事件码。)

常量值:4 (0x00000004)

int GPS_EVENT_STARTED

GPS系统模块被开启之后发送此事件码。

常量值:1 (0x00000001)

int GPS_EVENT_STOPPED

GPS系统模块被关闭之后发送此事件码。

常量值:2 (0x00000002)

内部类

interface GpsStatus.Listener

用于接收当GPS状态发生改变时所发出的通知

interface GpsStatus.NmeaListener

用于从GPS接收NMEA信息。

公共方法

public int getMaxSatellites ()

返回通过getSatellites()方法返回的卫星列表的最大卫星数。

返回值

最大卫星数。

public Iterable<GpsSatellite> getSatellites ()

返回一组用于描述GPS引擎当前状态的卫星对象。

返回值

一组卫星对象。

public int getTimeToFirstFix ()

返回自GPS引擎最新启动以来至收到的首次定位所需的时间。

返回值

首次定位所需的时间

补充

文章精选

百度百科 GPS

Android定位功能(一)

Android定位功能(二)


上一篇:下一篇: