PageRenderTime 40ms CodeModel.GetById 30ms app.highlight 5ms RepoModel.GetById 2ms app.codeStats 0ms

/src/com/google/maps/extras/xmlparsers/kml/LatLonBox.as

http://gmaps-utility-library-flash.googlecode.com/
ActionScript | 47 lines | 22 code | 6 blank | 19 comment | 0 complexity | eff8f162bf8a53ee2282b49a5789cb53 MD5 | raw file
 1/*
 2* Copyright 2008 Google Inc. 
 3* Licensed under the Apache License, Version 2.0:
 4*  http://www.apache.org/licenses/LICENSE-2.0
 5*/
 6package com.google.maps.extras.xmlparsers.kml
 7{
 8    import com.google.maps.extras.xmlparsers.Namespaces;
 9	import com.google.maps.extras.xmlparsers.ParsingTools;
10	import com.google.maps.extras.xmlparsers.XmlElement;
11
12	/**
13	*	Class that represents a <LatLonBox> element.
14	* 
15	* 	@see http://code.google.com/apis/kml/documentation/kmlreference.html#latlonbox
16	*/
17	public class LatLonBox extends AbstractLatLonBox
18	{
19		//todo: add constants for the enum values?
20		
21		private var _rotation:Number;		
22  
23		/**
24		*	Constructor for class.
25		* 
26		*	@param x
27		*/	
28		public function LatLonBox(x:XMLList)
29		{
30			super(x);
31			this._rotation  = ParsingTools.nanCheck(this.x.kml::rotation);
32		}
33	 	
34	 	
35	 	/**
36		*	Represents the <rotation> child element.
37		*/	
38		public function get rotation():Number
39		{
40			return this._rotation;
41	 	}
42	 	
43	 	public override function toString():String {
44	 		return "LatLonBox: " + super.toString() + " rotation: " + this._rotation;
45	 	}
46	}
47}