PageRenderTime 38ms CodeModel.GetById 22ms RepoModel.GetById 0ms app.codeStats 0ms

/src/com/google/maps/extras/arcgislink/json/JSONParseError.as

http://gmaps-utility-library-flash.googlecode.com/
ActionScript | 89 lines | 18 code | 8 blank | 63 comment | 0 complexity | 9b745d281bffeba5ff7decd1709c547f MD5 | raw file
  1. /*
  2. Copyright (c) 2008, Adobe Systems Incorporated
  3. All rights reserved.
  4. Redistribution and use in source and binary forms, with or without
  5. modification, are permitted provided that the following conditions are
  6. met:
  7. * Redistributions of source code must retain the above copyright notice,
  8. this list of conditions and the following disclaimer.
  9. * Redistributions in binary form must reproduce the above copyright
  10. notice, this list of conditions and the following disclaimer in the
  11. documentation and/or other materials provided with the distribution.
  12. * Neither the name of Adobe Systems Incorporated nor the names of its
  13. contributors may be used to endorse or promote products derived from
  14. this software without specific prior written permission.
  15. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
  16. IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
  17. THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  18. PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
  19. CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
  20. EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
  21. PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
  22. PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
  23. LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
  24. NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
  25. SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  26. */
  27. //http://code.google.com/p/as3corelib/
  28. //package com.adobe.serialization.json
  29. package com.google.maps.extras.arcgislink.json {
  30. /**
  31. *
  32. *
  33. */
  34. public class JSONParseError extends Error {
  35. /** The location in the string where the error occurred */
  36. private var _location:int;
  37. /** The string in which the parse error occurred */
  38. private var _text:String;
  39. /**
  40. * Constructs a new JSONParseError.
  41. *
  42. * @param message The error message that occured during parsing
  43. * @langversion ActionScript 3.0
  44. * @playerversion Flash 9.0
  45. * @tiptext
  46. */
  47. public function JSONParseError( message:String = "", location:int = 0, text:String = "") {
  48. super( message );
  49. name = "JSONParseError";
  50. _location = location;
  51. _text = text;
  52. }
  53. /**
  54. * Provides read-only access to the location variable.
  55. *
  56. * @return The location in the string where the error occurred
  57. * @langversion ActionScript 3.0
  58. * @playerversion Flash 9.0
  59. * @tiptext
  60. */
  61. public function get location():int {
  62. return _location;
  63. }
  64. /**
  65. * Provides read-only access to the text variable.
  66. *
  67. * @return The string in which the error occurred
  68. * @langversion ActionScript 3.0
  69. * @playerversion Flash 9.0
  70. * @tiptext
  71. */
  72. public function get text():String {
  73. return _text;
  74. }
  75. }
  76. }