001 package com.google.gwt.maps.client.streetview; 002 003 import com.google.gwt.core.client.JavaScriptObject; 004 import com.google.gwt.maps.client.workaround.WorkAroundUtils; 005 006 /** 007 * A point of view object which specifies the camera's orientation at the Street View panorama's position. The point of view is defined as heading, pitch and zoom. 008 */ 009 public class StreetViewPov extends JavaScriptObject { 010 011 /** 012 * A point of view object which specifies the camera's orientation at the Street View panorama's position. The point of view is defined as heading, pitch and zoom. 013 * use newInstance(); 014 */ 015 protected StreetViewPov() {} 016 017 /** 018 * creates A point of view object which specifies the camera's orientation at the Street View panorama's position. The point of view is defined as heading, pitch and zoom. 019 */ 020 public final static StreetViewPov newInstance() { 021 JavaScriptObject jso = JavaScriptObject.createObject(); 022 WorkAroundUtils.removeGwtObjectId(jso); 023 return jso.cast(); 024 } 025 026 /** 027 * sets The camera heading in degrees relative to true north. True north is 0°, east is 90°, south is 180°, west is 270°. 028 * @param heading 029 */ 030 public final native void setHeading(int heading) /*-{ 031 this.heading = heading; 032 }-*/; 033 034 /** 035 * gets The camera heading in degrees relative to true north. True north is 0°, east is 90°, south is 180°, west is 270°. 036 */ 037 public final native int getHeading() /*-{ 038 return this.heading; 039 }-*/; 040 041 /** 042 * sets The camera pitch in degrees, relative to the street view vehicle. Ranges from 90° (directly upwards) to -90° (directly downwards). 043 * @param pitch 044 */ 045 public final native void setPitch(int pitch) /*-{ 046 this.pitch = pitch; 047 }-*/; 048 049 /** 050 * gets The camera pitch in degrees, relative to the street view vehicle. Ranges from 90° (directly upwards) to -90° (directly downwards). 051 */ 052 public final native int getPitch() /*-{ 053 return this.pitch; 054 }-*/; 055 056 /** 057 * sets The zoom level. Fully zoomed-out is level 0, zooming in increases the zoom level. 058 * @param zoom 059 */ 060 public final native void setZoom(int zoom) /*-{ 061 this.zoom = zoom; 062 }-*/; 063 064 /** 065 * gets The zoom level. Fully zoomed-out is level 0, zooming in increases the zoom level. 066 */ 067 public final native int getZoom() /*-{ 068 return this.zoom; 069 }-*/; 070 071 }