/*-------------------------------------------------[ Properties ]---------------------------------------------------
960109
protected boolean _setProperty(String name, Object value) throws SAXNotSupportedException{
        if(LEXICAL_HANDLER.equals(name) || LEXICAL_HANDLER_ALT.equals(name)){
            if(value==null || value instanceof LexicalHandler){
                handler.setLexicalHandler((LexicalHandler)value);
                return true;
            }else
                throw new SAXNotSupportedException("value must implement "+LexicalHandler.class);
        }else if(DECL_HANDLER.equals(name) || DECL_HANDLER_ALT.equals(name)){
            if(value==null || value instanceof DeclHandler){
                handler.setDeclHandler((DeclHandler)value);
                return true;
            }else
                throw new SAXNotSupportedException("value must implement "+DeclHandler.class);
        }else
            return false;
    }
12020
@Override
    public boolean setProperties(Dictionary<String, String> properties) {
        this.properties = properties;
        if (this.properties != null)
        {
            if (properties.get("debug") != null)
                debug = Integer.parseInt(properties.get("debug"));

            if (properties.get("input") != null)
                input = Integer.parseInt(properties.get("input"));

            if (properties.get("output") != null)
                output = Integer.parseInt(properties.get("output"));

            listings = Boolean.parseBoolean(properties.get("listings"));

            if (properties.get("readonly") != null)
                readOnly = Boolean.parseBoolean(properties.get("readonly"));

            if (properties.get("sendfileSize") != null)
                sendfileSize = 
                    Integer.parseInt(properties.get("sendfileSize")) * 1024;

            fileEncoding = properties.get("fileEncoding");

            globalXsltFile = properties.get("globalXsltFile");
            contextXsltFile = properties.get("contextXsltFile");
            localXsltFile = properties.get("localXsltFile");
            readmeFile = properties.get("readmeFile");

            if (properties.get("useAcceptRanges") != null)
                useAcceptRanges = Boolean.parseBoolean(properties.get("useAcceptRanges"));

            // Sanity check on the specified buffer sizes
            if (input < 256)
                input = 256;
            if (output < 256)
                output = 256;

            if (debug > 0) {
                log("DefaultServlet.init:  input buffer size=" + input +
                    ", output buffer size=" + output);
            }

            return this.setDocBase(this.properties.get(BASE_PATH));
        }
        else
        {
            return this.setDocBase(null);
        }
    }
1322743
function(parameters) {
            var that = this;
            _.each(parameters, function(params, property) {
                that.__setPropertyParam(property, params);
            });
            return that;
        }
993203
public function index($properties)
    {
        $properties = (array) $properties;

        foreach ($properties as $property)
        {
            $this->addCommand('index', ['property' => $property]);
        }
    }
906437
function () {
		var properties = this.properties;
		_.forEach(properties, function (prop, name) {
			prop = this.getProperty(name);
			this.stopListening(prop, EVENT_CHANGE);
		}, this);
	}
612146
function propertiesToActions() {
    for (var k in properties) {
      var prop = properties[k];
      switch (k) {
        case 'center':
          var pos = prop.value;
          if (properties.zoom === undefined) {
            actions.push({
              order: prop.order,
              cmd: 'S.map.actions.panTo([' + pos[0] + ',' + pos[1] + '])'
            });
          } else {
            actions.push({
              order: prop.order,
              cmd: 'S.map.actions.setView([' + pos[0] + ',' + pos[1] + '], ' + properties.zoom.value + ')'
            });
          }
        case 'zoom':
          if (!properties.center) {
            actions.push({
              order: prop.order,
              cmd: 'S.map.actions.setZoom(' + properties.zoom.value+ ')'
            });
          }
      }
    }
  }
1358479
public function property()
    {
        if ($this->property === null) {
            $this->property = $this->createProperty();
        }

        return $this->property;
    }
1331175
function (name, newValue) {
		var property = this.getProperty(name);
		if (!property) {
			this.initProperty(name, newValue);
		}
		else {
			property.set(newValue);
		}
	}
1346262
public function assign($property, $value)
	{
		if (null === $this->object)
		{
			$this->object = new Object;
		}

		$this->object->assign($property, $value);

		return $this;
	}
384725
public function propertiesRules()
    {
        $rules = [];
        $this->ensurePropertiesAttributes();

        if (empty($this->propertiesIds) === false) {
            foreach ($this->propertiesIds as $propertyId) {
                /** @var Property $property */
                $property = Property::findById($propertyId);
                $handler = $property->handler();

                $rules = ArrayHelper::merge($rules, $handler->getValidationRules($property));
                if ($property->isRequired()) {
                    $rules = ArrayHelper::merge($rules, [[$property->key, 'required']]);
                }
            }
        }
        return $rules;
    }
22098
protected void initProperties(Properties properties) {

        for (Enumeration keys = properties.keys(); keys.hasMoreElements();) {

            final String key = (String) keys.nextElement();
    
            // caonical-form
            // Other features will be enabled or disabled when this is set to true or false.

            // error-handler; set via the constructor

            // infoset
            // Other features will be enabled or disabled when this is set to true

            // A quick lookup for the given set of properties (cdata-sections ...)
            final Object iobj = s_propKeys.get(key);
            if (iobj != null) {
                if (iobj instanceof Integer) {
                    // Dealing with a property that has a simple bit value that
                    // we need to set

                    // cdata-sections			
                    // comments
                    // element-content-whitespace
                    // entities
                    // namespaces
                    // namespace-declarations
                    // split-cdata-sections
                    // well-formed
                    // discard-default-content
                    final int BITFLAG = ((Integer) iobj).intValue();
                    if ((properties.getProperty(key).endsWith("yes"))) {
                        fFeatures = fFeatures | BITFLAG;
                    } else {
                        fFeatures = fFeatures & ~BITFLAG;
                    }
                } else {
                    // We are interested in the property, but it is not
                    // a simple bit that we need to set.

                    if ((DOMConstants.S_DOM3_PROPERTIES_NS
                        + DOMConstants.DOM_FORMAT_PRETTY_PRINT)
                        .equals(key)) {
                        // format-pretty-print; set internally on the serializers via xsl:output properties in LSSerializer
                        if ((properties.getProperty(key).endsWith("yes"))) {
                            fSerializer.setIndent(true);
                            fSerializer.setIndentAmount(3);
                        } else {
                            fSerializer.setIndent(false);
                        }
                    } else if (
                        (DOMConstants.S_XSL_OUTPUT_OMIT_XML_DECL).equals(
                            key)) {
                        // omit-xml-declaration; set internally on the serializers via xsl:output properties in LSSerializer
                        if ((properties.getProperty(key).endsWith("yes"))) {
                            fSerializer.setOmitXMLDeclaration(true);
                        } else {
                            fSerializer.setOmitXMLDeclaration(false);
                        }
                    } else if (
                        (
                            DOMConstants.S_XERCES_PROPERTIES_NS
                                + DOMConstants.S_XML_VERSION).equals(
                            key)) {
                        // Retreive the value of the XML Version attribute via the xml-version
                        String version = properties.getProperty(key);
                        if ("1.1".equals(version)) {
                            fIsXMLVersion11 = true;
                            fSerializer.setVersion(version);
                        } else {
                            fSerializer.setVersion("1.0");
                        }
                    } else if (
                        (DOMConstants.S_XSL_OUTPUT_ENCODING).equals(key)) {
                        // Retreive the value of the XML Encoding attribute
                        String encoding = properties.getProperty(key);
                        if (encoding != null) {
                            fSerializer.setEncoding(encoding);
                        }
                    } else if ((DOMConstants.S_XERCES_PROPERTIES_NS
                            + DOMConstants.DOM_ENTITIES).equals(key)) {
                        // Preserve entity references in the document
                        if ((properties.getProperty(key).endsWith("yes"))) {
                            fSerializer.setDTDEntityExpansion(false);
                        }
                        else {
                            fSerializer.setDTDEntityExpansion(true);
                        }
                    } else {
                        // We shouldn't get here, ever, now what?
                    }
                }
            }
        }
        // Set the newLine character to use
        if (fNewLine != null) {
            fSerializer.setOutputProperty(OutputPropertiesFactory.S_KEY_LINE_SEPARATOR, fNewLine);
        }
    }
1098221
@Override
    public void setProperties(Map<Object, Object> properties) {

        Iterator<Object> keys = properties.keySet().iterator();
        while (keys.hasNext()) {
            Object key = keys.next();
            lazyProperties().put(key, properties.get(key));
        }
    }
813077
function(property, param, value) {
            var params = {};

            if (!_.isUndefined(value)) {
                params[param] = value;
            }
            else if (_.isObject(param)) {
                _.extend(params, param);
            }

            if (!(property in this.__properties)) {
                this.__properties[property] = {};
            }

            _.extend(this.__properties[property], params);

            return this;
        }
942507
function (cb, context) {
        context !== void 0 && (cb = bind(cb, context));
        for (var key in this.data) {
            this.data.hasOwnProperty(key) && cb(this.data[key], key);
        }
    }
50101
@Override
    public void setProperty(Object description, Object property) {
        lazyProperties().put(description, property);
        notifyChanged();
    }
1137216
synchronized void setProperty(final String name, final String value) {
        Hashtable<String, String> properties = new Hashtable<String, String>(this.properties);
        properties.put(name, value);

        this.properties = properties;
    }
903862
@Override
    protected void setProperty(final String _name,
                               final String _value)
        throws CacheReloadException
    {
        if ("AskUser".equals(_name)) {
            askUser = "true".equalsIgnoreCase(_value);
        } else if ("DefaultSelected".equals(_name)) {
            defaultSelected = "true".equalsIgnoreCase(_value);
        } else if ("HRef".equals(_name)) {
            reference = _value;
        } else if ("Label".equals(_name)) {
            label = _value;
        } else if ("Submit".equals(_name)) {
            submit = "true".equalsIgnoreCase(_value);
        } else if ("SubmitSelectedRows".equals(_name)) {
            submitSelectedRows = Integer.parseInt(_value);
        } else if ("Target".equals(_name)) {
            if ("content".equals(_value)) {
                target = AbstractCommand.Target.CONTENT;
            } else if ("hidden".equals(_value)) {
                target = AbstractCommand.Target.HIDDEN;
            } else if ("popup".equals(_value)) {
                target = AbstractCommand.Target.POPUP;
            } else if ("modal".equals(_value)) {
                target = AbstractCommand.Target.MODAL;
            }
        } else if ("TargetBottomHeight".equals(_name)) {
            targetBottomHeight = Integer.parseInt(_value);
        } else if ("TargetCmdRevise".equals(_name)) {
            targetCmdRevise = "TRUE".equalsIgnoreCase(_value);
        } else if ("TargetConnectAttribute".equals(_name)) {
            final Attribute attr = Attribute.get(_value);
            targetConnectAttributeId = attr == null ? 0 : attr.getId();
        } else if ("TargetCreateType".equals(_name)) {
            final Type type = Type.get(_value);
            targetCreateTypeId = type == null ? 0 : type.getId();
        } else if (_name != null && _name.startsWith("TargetCreateClassifications")) {
            setTargetCreateClassifications(_value);
        } else if ("TargetDefaultMenu".equals(_name)) {
            targetDefaultMenu = "none".equalsIgnoreCase(_value);
        } else if ("TargetMode".equals(_name)) {
            if ("create".equals(_value)) {
                targetMode = TargetMode.CREATE;
            } else if ("edit".equals(_value)) {
                targetMode = TargetMode.EDIT;
            } else if ("connect".equals(_value)) {
                targetMode = TargetMode.CONNECT;
            } else if ("search".equals(_value)) {
                targetMode = TargetMode.SEARCH;
            } else if ("view".equals(_value)) {
                targetMode = TargetMode.VIEW;
            }
        } else if ("TargetShowCheckBoxes".equals(_name)) {
            targetShowCheckBoxes = "true".equalsIgnoreCase(_value);
        } else if ("TargetTableSortKey".equals(_name)) {
            targetTableSortKey = _value;
            targetTableSortDirection = AbstractCommand.SortDirection.ASCENDING;
        } else if ("TargetTableSortDirection".equals(_name)) {
            if (AbstractCommand.SortDirection.DESCENDING.value.equals(_value)) {
                targetTableSortDirection = AbstractCommand.SortDirection.DESCENDING;
            } else {
                targetTableSortDirection = AbstractCommand.SortDirection.ASCENDING;
            }
        } else if ("TargetTitle".equals(_name)) {
            targetTitle = _value;
        } else if ("TargetShowFile".equals(_name)) {
            targetShowFile = "true".equalsIgnoreCase(_value);
        } else if ("NoUpdateAfterCOMMAND".equals(_name)) {
            noUpdateAfterCmd = "true".equalsIgnoreCase(_value);
        } else if ("TargetStructurBrowserField".equals(_name)) {
            targetStructurBrowserField = _value.trim();
        } else if ("WindowHeight".equals(_name)) {
            windowHeight = Integer.parseInt(_value);
        } else if ("WindowWidth".equals(_name)) {
            windowWidth = Integer.parseInt(_value);
        } else {
            super.setProperty(_name, _value);
        }
    }