com.google.maps.gwt.client.DistanceMatrixResponseElement Maven / Gradle / Ivy
/*
* Copyright 2011 The Google Web Toolkit Authors.
*
* 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.
*/
package com.google.maps.gwt.client;
import com.google.gwt.core.client.JavaScriptObject;
/**
* A single element of a response to a
* DistanceMatrixService
*
* request, which contains the duration and distance from one origin to
* one destination.
*
* THIS SOURCE CODE IS GENERATED, DO NOT MODIFY
*/
public class DistanceMatrixResponseElement extends JavaScriptObject {
/**
* Protected constructor avoids default public constructor.
*/
protected DistanceMatrixResponseElement() {
/* Java constructor is protected, */
}
/**
* The distance for this origin-destination pairing. This property may
* be undefined as the distance may be unknown.
*/
public final native Distance getDistance()/*-{
return this.distance;
}-*/;
/**
* The duration for this origin-destination pairing. This property may
* be undefined as the duration may be unknown.
*/
public final native Duration getDuration()/*-{
return this.duration;
}-*/;
/**
* The status of this particular origin-destination pairing.
*/
public final native DistanceMatrixElementStatus getStatus()/*-{
var _retval = this.status;
var retval = (_retval == undefined) ?
null : @com.google.maps.gwt.client.DistanceMatrixElementStatus::fromValue(Ljava/lang/String;)(_retval);
return retval;
}-*/;
/**
* The distance for this origin-destination pairing. This property may
* be undefined as the distance may be unknown.
*/
public final native void setDistance(Distance distance)/*-{
this.distance = distance;
}-*/;
/**
* The duration for this origin-destination pairing. This property may
* be undefined as the duration may be unknown.
*/
public final native void setDuration(Duration duration)/*-{
this.duration = duration;
}-*/;
/**
* The status of this particular origin-destination pairing.
*/
public final native void setStatus(DistanceMatrixElementStatus status)/*-{
var _status = status == undefined ? null : status.value;
this.status = _status;
}-*/;
}