Comments, links, copyrights
This commit is contained in:
@@ -4,17 +4,15 @@ goog.provide('ol.expression.Literal');
|
|||||||
goog.provide('ol.expression.Not');
|
goog.provide('ol.expression.Not');
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Support an extremely limited subset of ECMAScript 5.1
|
* Base class for all expressions. Instances of ol.Expression correspond to
|
||||||
* http://www.ecma-international.org/ecma-262/5.1/
|
* a limited set of ECMAScript 5.1 expressions.
|
||||||
|
* http://www.ecma-international.org/ecma-262/5.1/#sec-11
|
||||||
|
*
|
||||||
|
* This base class should not be constructed directly. Instead, use one of
|
||||||
|
* the subclass constructors.
|
||||||
*
|
*
|
||||||
* Inspired by Esprima (https://github.com/ariya/esprima)
|
|
||||||
* BSD Licensed
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @constructor
|
* @constructor
|
||||||
*/
|
*/
|
||||||
ol.expression.Expression = function() {};
|
ol.expression.Expression = function() {};
|
||||||
|
|||||||
@@ -1,3 +1,18 @@
|
|||||||
|
/**
|
||||||
|
* The logic and naming of methods here are inspired by Esprima (BSD Licensed).
|
||||||
|
* Esprima (http://esprima.org) includes the following copyright notices:
|
||||||
|
*
|
||||||
|
* Copyright (C) 2013 Ariya Hidayat <ariya.hidayat@gmail.com>
|
||||||
|
* Copyright (C) 2013 Thaddee Tyl <thaddee.tyl@gmail.com>
|
||||||
|
* Copyright (C) 2012 Ariya Hidayat <ariya.hidayat@gmail.com>
|
||||||
|
* Copyright (C) 2012 Mathias Bynens <mathias@qiwi.be>
|
||||||
|
* Copyright (C) 2012 Joost-Wim Boekesteijn <joost-wim@boekesteijn.nl>
|
||||||
|
* Copyright (C) 2012 Kris Kowal <kris.kowal@cixar.com>
|
||||||
|
* Copyright (C) 2012 Yusuke Suzuki <utatane.tea@gmail.com>
|
||||||
|
* Copyright (C) 2012 Arpad Borsos <arpad.borsos@googlemail.com>
|
||||||
|
* Copyright (C) 2011 Ariya Hidayat <ariya.hidayat@gmail.com>
|
||||||
|
*/
|
||||||
|
|
||||||
goog.provide('ol.expression.Lexer');
|
goog.provide('ol.expression.Lexer');
|
||||||
goog.provide('ol.expression.Token');
|
goog.provide('ol.expression.Token');
|
||||||
goog.provide('ol.expression.TokenType');
|
goog.provide('ol.expression.TokenType');
|
||||||
@@ -79,7 +94,8 @@ ol.expression.Token;
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Lexer constructor.
|
* Lexer constructor. Provides a tokenizer for a limited subset of ECMAScript
|
||||||
|
* 5.1 expressions (http://www.ecma-international.org/ecma-262/5.1/#sec-11).
|
||||||
*
|
*
|
||||||
* @constructor
|
* @constructor
|
||||||
* @param {string} source Source code.
|
* @param {string} source Source code.
|
||||||
@@ -226,9 +242,10 @@ ol.expression.Lexer.prototype.isIdentifierStart_ = function(code) {
|
|||||||
/**
|
/**
|
||||||
* Determine if the given identifier is an ECMAScript keyword. These cannot
|
* Determine if the given identifier is an ECMAScript keyword. These cannot
|
||||||
* be used as identifiers in programs. There is no real reason these could not
|
* be used as identifiers in programs. There is no real reason these could not
|
||||||
* be used in ol expressions - so it might be worth allowing them.
|
* be used in ol expressions - but they are reserved for future use.
|
||||||
*
|
*
|
||||||
* http://www.ecma-international.org/ecma-262/5.1/#sec-7.6.1.1
|
* http://www.ecma-international.org/ecma-262/5.1/#sec-7.6.1.1
|
||||||
|
*
|
||||||
* @param {string} id Identifier.
|
* @param {string} id Identifier.
|
||||||
* @return {boolean} The identifier is a keyword.
|
* @return {boolean} The identifier is a keyword.
|
||||||
* @private
|
* @private
|
||||||
|
|||||||
@@ -1,3 +1,18 @@
|
|||||||
|
/**
|
||||||
|
* The logic and naming of methods here are inspired by Esprima (BSD Licensed).
|
||||||
|
* Esprima (http://esprima.org) includes the following copyright notices:
|
||||||
|
*
|
||||||
|
* Copyright (C) 2013 Ariya Hidayat <ariya.hidayat@gmail.com>
|
||||||
|
* Copyright (C) 2013 Thaddee Tyl <thaddee.tyl@gmail.com>
|
||||||
|
* Copyright (C) 2012 Ariya Hidayat <ariya.hidayat@gmail.com>
|
||||||
|
* Copyright (C) 2012 Mathias Bynens <mathias@qiwi.be>
|
||||||
|
* Copyright (C) 2012 Joost-Wim Boekesteijn <joost-wim@boekesteijn.nl>
|
||||||
|
* Copyright (C) 2012 Kris Kowal <kris.kowal@cixar.com>
|
||||||
|
* Copyright (C) 2012 Yusuke Suzuki <utatane.tea@gmail.com>
|
||||||
|
* Copyright (C) 2012 Arpad Borsos <arpad.borsos@googlemail.com>
|
||||||
|
* Copyright (C) 2011 Ariya Hidayat <ariya.hidayat@gmail.com>
|
||||||
|
*/
|
||||||
|
|
||||||
goog.provide('ol.expression.Parser');
|
goog.provide('ol.expression.Parser');
|
||||||
|
|
||||||
goog.require('goog.asserts');
|
goog.require('goog.asserts');
|
||||||
|
|||||||
Reference in New Issue
Block a user