⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 literal.as

📁 用于flash/flex的 as3的 2D图形图像图表的动态生成
💻 AS
字号:
package flare.query
{	
	/**
	 * Expression operator for a literal value.
	 */
	public class Literal extends Expression
	{
		/** The boolean true literal. */
		public static const TRUE:Literal = new Literal(true);
		/** The boolean false literal. */
		public static const FALSE:Literal = new Literal(false);
		
		private var _value:Object = null;
		
		/** The literal value of this expression. */
		public function get value():Object { return _value; }
		public function set value(val:Object):void { _value = val; }
		
		/**
		 * Creates a new Literal instance.
		 * @param val the literal value
		 */
		public function Literal(val:Object=null) {
			_value = val;
		}
		
		/**
		 * @inheritDoc
		 */
		public override function clone():Expression
		{
			return new Literal(_value);
		}
		
		/**
		 * @inheritDoc
		 */
		public override function predicate(o:Object):Boolean
		{
			return Boolean(_value);
		}
		
		/**
		 * @inheritDoc
		 */
		public override function eval(o:Object=null):*
		{
			return _value;
		}
		
		/**
		 * @inheritDoc
		 */
		public override function toString():String
		{
			return String(_value);
		}
		
	} // end of class Literal
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -