Gets the page priority from a list of properties.<p>

If the page priority can't be found among the properties, -1 will be returned.<p>

@param properties the properties of a resource

@return the page priority read from the properties, or -1
519016
protected static double getPriority(List<CmsProperty> properties) {

        CmsProperty prop = CmsProperty.get(CmsPropertyDefinition.PROPERTY_XMLSITEMAP_PRIORITY, properties);
        if (prop.isNullProperty()) {
            return -1.0;
        }
        try {
            double result = Double.parseDouble(prop.getValue().trim());
            return result;
        } catch (NumberFormatException e) {
            return -1.0;
        }
    }
441908
@Nonnull
	private static Properties findDefaultProperties() {
		final InputStream in = SourceCodeFormatter.class.getClassLoader().getResourceAsStream(DEFAULT_PROPERTIES_PATH);
		final Properties p = new Properties();
		try {
			p.load(in);
		} catch (final IOException e) {
			throw new RuntimeException(String.format("Can not load resource %s", DEFAULT_PROPERTIES_PATH));
		}
		return p;
	}
705497
public final int getWriteIndex(String property) {
    MethodInfo method = propertyWriteMethods.get(property);
    return (null == method) ? -1 : method.index;
  }
43202
protected Map<String, CmsProperty> getPropertiesByName(List<CmsProperty> properties) {

        Map<String, CmsProperty> result = new HashMap<String, CmsProperty>();
        for (CmsProperty property : properties) {
            String key = property.getName();
            result.put(key, property.clone());
        }
        return result;
    }
1253798
public String getProperty(final String property) {
        if (System.getSecurityManager() == null)
            return System.getProperty(property);
        return AccessController.doPrivileged(new PrivilegedAction<String>() {
            @Override
            public String run() {
                return System.getProperty(property);
            }
        }, controlContext);
    }
834378
public static int getRunPriority() {
        String s = System.getProperty(RUN_PRIORITY_PROPERTY);
        int priority = Thread.NORM_PRIORITY;
        if (s != null) {
            try {
                priority  = Integer.parseInt(s);
            } catch (NumberFormatException ex) {
                // priority remains Thread.NORM_PRIORITY
            }
        }
        return priority;
    }
1297514
public static <T> T getValue(ValuedProperty<T> property) {
		return (property == null) ? null : property.getValue();
	}
341965
public Properties getProperties() {
        if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
            Tr.debug(tc, "getProperties");
        return this.sslProperties;
    }
1221797
public R fetch(String properties) {
    ((TQRootBean) _root).query().fetch(_name, properties);
    return _root;
  }
324123
public BaseScreen getScreen(Map<String,Object> properties)
    {
        if (m_topScreen == null)
            m_topScreen = (ScreenModel)this.createTopScreen(this.getTask(), null);
        BaseScreen screen = null;
        if (m_topScreen.getSFieldCount() > 0)
            screen = (BaseScreen)m_topScreen.getSField(0);
        this.setProperties(properties);
        BaseScreen newScreen = (BaseScreen)m_topScreen.getScreen(screen, this);
        return newScreen;
    }
1279321
public Collection<String> getValues(String property) {
        Multimap<Optional<String>, String> values = properties.get(property);
        if (values == null) {
            return Collections.emptyList();
        }

        return values.values();
    }
1078052
public Example excludeProperties(String... properties) {
        if (properties != null && properties.length > 0) {
            if (this.excludeColumns == null) {
                this.excludeColumns = new LinkedHashSet<String>();
            }
            for (String property : properties) {
                if (propertyMap.containsKey(property)) {
                    this.excludeColumns.add(propertyMap.get(property).getColumn());
                } else {
                    throw new MapperException("类 " + entityClass.getSimpleName() + " 不包含属性 \'" + property + "\'，或该属性被@Transient注释！");
                }
            }
        }
        return this;
    }
876030
public Map<String, String> getPropertiesAsMap(Properties properties) {
		Map<String, String> result = new HashMap<String, String>();
		for (String key : properties.stringPropertyNames()) {
			result.put(key, properties.getProperty(key));
		}
		return result;
	}
530576
@SuppressWarnings("unchecked")
    public SearchKeyFactory<S> getSearchKeyFactory(OrderedProperty<S>[] properties) {
        // This KeyFactory makes arrays work as hashtable keys.
        Object key = KeyFactory.createKey(new Object[] {mCodecKey, properties});

        synchronized (cCodecSearchKeyFactories) {
            SearchKeyFactory<S> factory = (SearchKeyFactory<S>) cCodecSearchKeyFactories.get(key);
            if (factory == null) {
                factory = generateSearchKeyFactory(properties);
                cCodecSearchKeyFactories.put(key, factory);
            }
            return factory;
        }
    }
1177197
public void parseProperties(Properties properties, MultipartRequest multi)
	{
		Enumeration<?> params = multi.getParameterNames();
		while (params.hasMoreElements()) {
			String name = (String)params.nextElement();
			String value = multi.getParameter(name);
			if (value != null)
				properties.setProperty(name, value);
			if (DEBUG)
				System.out.println(name + " = " + value);
		}
	}
347499
public List<JoinableResourceBundle> getResourceBundles(Properties properties) {

		PropertiesConfigHelper props = new PropertiesConfigHelper(properties, resourceType);
		String fileExtension = "." + resourceType;

		// Initialize custom bundles
		List<JoinableResourceBundle> customBundles = new ArrayList<>();
		// Check if we should use the bundle names property or
		// find the bundle name using the bundle id declaration :
		// jawr.<type>.bundle.<name>.id
		if (null != props.getProperty(PropertiesBundleConstant.BUNDLE_FACTORY_CUSTOM_NAMES)) {
			StringTokenizer tk = new StringTokenizer(
					props.getProperty(PropertiesBundleConstant.BUNDLE_FACTORY_CUSTOM_NAMES), ",");
			while (tk.hasMoreTokens()) {
				customBundles
						.add(buildJoinableResourceBundle(props, tk.nextToken().trim(), fileExtension, rsReaderHandler));
			}
		} else {
			Iterator<String> bundleNames = props.getPropertyBundleNameSet().iterator();
			while (bundleNames.hasNext()) {
				customBundles
						.add(buildJoinableResourceBundle(props, bundleNames.next(), fileExtension, rsReaderHandler));
			}
		}

		// Initialize the bundles dependencies
		Iterator<String> bundleNames = props.getPropertyBundleNameSet().iterator();
		while (bundleNames.hasNext()) {
			String bundleName = (String) bundleNames.next();
			List<String> bundleNameDependencies = props.getCustomBundlePropertyAsList(bundleName,
					PropertiesBundleConstant.BUNDLE_FACTORY_CUSTOM_DEPENDENCIES);
			if (!bundleNameDependencies.isEmpty()) {
				JoinableResourceBundle bundle = getBundleFromName(bundleName, customBundles);
				List<JoinableResourceBundle> bundleDependencies = getBundlesFromName(bundleNameDependencies,
						customBundles);
				bundle.setDependencies(bundleDependencies);
			}
		}

		return customBundles;
	}
542656
public void setProperties(Properties properties) {
		script = properties.getProperty("script", script);
		pageIntervalInMinutes = Integer.parseInt(properties.getProperty("page_interval_in_minutes",
				"" + pageIntervalInMinutes));
		pageOffsetInMinutes = Integer.parseInt(properties.getProperty("page_offset_in_minutes",
				"" + pageOffsetInMinutes));
	}