PageRenderTime 29ms CodeModel.GetById 15ms app.highlight 7ms RepoModel.GetById 2ms app.codeStats 0ms

/src/com/google/maps/extras/xmlparsers/atom/Author.as

http://gmaps-utility-library-flash.googlecode.com/
ActionScript | 75 lines | 28 code | 9 blank | 38 comment | 0 complexity | 3e43e79dbc485879b0743f17717d6cf9 MD5 | raw file
 1/*
 2        Copyright (c) 2008, Adobe Systems Incorporated
 3        All rights reserved.
 4
 5        Redistribution and use in source and binary forms, with or without 
 6        modification, are permitted provided that the following conditions are
 7        met:
 8
 9    * Redistributions of source code must retain the above copyright notice, 
10        this list of conditions and the following disclaimer.
11    * Redistributions in binary form must reproduce the above copyright
12                notice, this list of conditions and the following disclaimer in the 
13        documentation and/or other materials provided with the distribution.
14    * Neither the name of Adobe Systems Incorporated nor the names of its 
15        contributors may be used to endorse or promote products derived from 
16        this software without specific prior written permission.
17
18        THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
19        IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
20        THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
21        PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR 
22        CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
23        EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
24        PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
25        PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
26        LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
27        NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28        SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29*/
30
31package com.google.maps.extras.xmlparsers.atom
32{
33	import com.google.maps.extras.xmlparsers.XmlElement;
34	import com.google.maps.extras.xmlparsers.XmlParser;
35	import com.google.maps.extras.xmlparsers.ParsingTools;
36	import com.google.maps.extras.xmlparsers.Namespaces;
37	
38	public class Author extends XmlElement {
39	
40	private var atom:Namespace = Namespaces.ATOM_NS;
41
42	private var _name:String;
43	private var _email:String;
44	private var _uri:String;
45	
46	/**
47	*	Class that represents an author element within an Atom feed.
48	* 
49	* 	@langversion ActionScript 3.0
50	*	@playerversion Flash 8.5
51	*	@tiptext
52	* 
53	* 	@see http://www.atomenabled.org/developers/syndication/atom-format-spec.php#rfc.section.4.2.1
54	*/		
55	
56	public function Author(x:XMLList) {
57		super(x);
58		this._name = ParsingTools.nullCheck(this.x.atom::author.@["name"]);
59		this._email = ParsingTools.nullCheck(this.x.atom::author.email);
60		this._uri = ParsingTools.nullCheck(this.x.atom::author.uri);
61	}
62	
63	public function get name():String {
64		return this._name;
65	}
66	
67	public function get email():String {
68		return this._email;
69	}
70	
71	public function get uri():String {
72		return this._uri;
73	}
74    }
75}