Blink roll 25b6bd3a7a131ffe68d809546ad1a20707915cdc:3a503f41ae42e5b79cfcd2ff10e65afde...
[chromium-blink-merge.git] / content / common / geofencing_status.cc
blobffca197bc85327c26e4a691d5d55215454c479b0
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "content/common/geofencing_status.h"
7 #include "base/logging.h"
9 namespace content {
11 const char* GeofencingStatusToString(GeofencingStatus status) {
12 switch (status) {
13 case GEOFENCING_STATUS_OK:
14 return "Operation has succeeded";
16 case GEOFENCING_STATUS_OPERATION_FAILED_NO_SERVICE_WORKER:
17 return "Operation failed - no Service Worker";
19 case GEOFENCING_STATUS_OPERATION_FAILED_SERVICE_NOT_AVAILABLE:
20 return "Operation failed - geofencing not available";
22 case GEOFENCING_STATUS_UNREGISTRATION_FAILED_NOT_REGISTERED:
23 return "Unregistration failed - no region registered with given ID";
25 case GEOFENCING_STATUS_ERROR:
26 return "Operation has failed (unspecified reason)";
28 NOTREACHED();
29 return "";
32 } // namespace content