org.springframework.core.Constants.propertyToConstantNamePrefix()方法的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(7.7k)|赞(0)|评价(0)|浏览(120)

本文整理了Java中org.springframework.core.Constants.propertyToConstantNamePrefix()方法的一些代码示例,展示了Constants.propertyToConstantNamePrefix()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Constants.propertyToConstantNamePrefix()方法的具体详情如下:
包路径:org.springframework.core.Constants
类名称:Constants
方法名:propertyToConstantNamePrefix

Constants.propertyToConstantNamePrefix介绍

[英]Convert the given bean property name to a constant name prefix.

Uses a common naming idiom: turning all lower case characters to upper case, and prepending upper case characters with an underscore.

Example: "imageSize" -> "IMAGE_SIZE"
Example: "imagesize" -> "IMAGESIZE".
Example: "ImageSize" -> "_IMAGE_SIZE".
Example: "IMAGESIZE" -> "_I_M_A_G_E_S_I_Z_E"
[中]将给定的bean属性名称转换为常量名称前缀。
使用一种常见的命名习惯用法:将所有小写字符转换为大写,并在大写字符前加下划线。
示例:“图像大小”->“图像大小”
示例:“imagesize”->“imagesize”。
示例:“图像大小”->“图像大小”。
示例:“IMAGESIZE”->“_I_M_A_G_E_S_I_Z_E”

代码示例

代码示例来源:origin: spring-projects/spring-framework

/**
 * Return all names of the group of constants for the
 * given bean property name.
 * @param propertyName the name of the bean property
 * @return the set of values
 * @see #propertyToConstantNamePrefix
 */
public Set<String> getNamesForProperty(String propertyName) {
  return getNames(propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: spring-projects/spring-framework

/**
 * Return all values of the group of constants for the
 * given bean property name.
 * @param propertyName the name of the bean property
 * @return the set of values
 * @see #propertyToConstantNamePrefix
 */
public Set<Object> getValuesForProperty(String propertyName) {
  return getValues(propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: spring-projects/spring-framework

/**
 * Look up the given value within the group of constants for
 * the given bean property name. Will return the first match.
 * @param value constant value to look up
 * @param propertyName the name of the bean property
 * @return the name of the constant field
 * @throws ConstantException if the value wasn't found
 * @see #propertyToConstantNamePrefix
 */
public String toCodeForProperty(Object value, String propertyName) throws ConstantException {
  return toCode(value, propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: org.springframework/spring-core

/**
 * Look up the given value within the group of constants for
 * the given bean property name. Will return the first match.
 * @param value constant value to look up
 * @param propertyName the name of the bean property
 * @return the name of the constant field
 * @throws ConstantException if the value wasn't found
 * @see #propertyToConstantNamePrefix
 */
public String toCodeForProperty(Object value, String propertyName) throws ConstantException {
  return toCode(value, propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: org.springframework/spring-core

/**
 * Return all values of the group of constants for the
 * given bean property name.
 * @param propertyName the name of the bean property
 * @return the set of values
 * @see #propertyToConstantNamePrefix
 */
public Set<Object> getValuesForProperty(String propertyName) {
  return getValues(propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: org.springframework/spring-core

/**
 * Return all names of the group of constants for the
 * given bean property name.
 * @param propertyName the name of the bean property
 * @return the set of values
 * @see #propertyToConstantNamePrefix
 */
public Set<String> getNamesForProperty(String propertyName) {
  return getNames(propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: camunda/camunda-bpm-platform

/**
 * Look up the given value within the group of constants for
 * the given bean property name. Will return the first match.
 * @param value constant value to look up
 * @param propertyName the name of the bean property
 * @return the name of the constant field
 * @throws ConstantException if the value wasn't found
 * @see #propertyToConstantNamePrefix
 */
public String toCodeForProperty(Object value, String propertyName) throws ConstantException {
  return toCode(value, propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: camunda/camunda-bpm-platform

/**
 * Return all names of the group of constants for the
 * given bean property name.
 * @param propertyName the name of the bean property
 * @return the set of values
 * @see #propertyToConstantNamePrefix
 */
public Set<String> getNamesForProperty(String propertyName) {
  return getNames(propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: camunda/camunda-bpm-platform

/**
 * Return all values of the group of constants for the
 * given bean property name.
 * @param propertyName the name of the bean property
 * @return the set of values
 * @see #propertyToConstantNamePrefix
 */
public Set<Object> getValuesForProperty(String propertyName) {
  return getValues(propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: apache/servicemix-bundles

/**
 * Return all names of the group of constants for the
 * given bean property name.
 * @param propertyName the name of the bean property
 * @return the set of values
 * @see #propertyToConstantNamePrefix
 */
public Set<String> getNamesForProperty(String propertyName) {
  return getNames(propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: apache/servicemix-bundles

/**
 * Look up the given value within the group of constants for
 * the given bean property name. Will return the first match.
 * @param value constant value to look up
 * @param propertyName the name of the bean property
 * @return the name of the constant field
 * @throws ConstantException if the value wasn't found
 * @see #propertyToConstantNamePrefix
 */
public String toCodeForProperty(Object value, String propertyName) throws ConstantException {
  return toCode(value, propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: apache/servicemix-bundles

/**
 * Return all values of the group of constants for the
 * given bean property name.
 * @param propertyName the name of the bean property
 * @return the set of values
 * @see #propertyToConstantNamePrefix
 */
public Set<Object> getValuesForProperty(String propertyName) {
  return getValues(propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.spring-core

/**
 * Look up the given value within the group of constants for
 * the given bean property name. Will return the first match.
 * @param value constant value to look up
 * @param propertyName the name of the bean property
 * @return the name of the constant field
 * @throws ConstantException if the value wasn't found
 * @see #propertyToConstantNamePrefix
 */
public String toCodeForProperty(Object value, String propertyName) throws ConstantException {
  return toCode(value, propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: springframework/spring-core

/**
 * Look up the given value within the group of constants for
 * the given bean property name. Will return the first match.
 * @param value constant value to look up
 * @param propertyName the name of the bean property
 * @return the name of the constant field
 * @throws ConstantException if the value wasn't found
 * @see #propertyToConstantNamePrefix
 */
public String toCodeForProperty(Object value, String propertyName) throws ConstantException {
  return toCode(value, propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.spring-core

/**
 * Return all names of the group of constants for the
 * given bean property name.
 * @param propertyName the name of the bean property
 * @return the set of values
 * @see #propertyToConstantNamePrefix
 */
public Set<String> getNamesForProperty(String propertyName) {
  return getNames(propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.spring-core

/**
 * Return all values of the group of constants for the
 * given bean property name.
 * @param propertyName the name of the bean property
 * @return the set of values
 * @see #propertyToConstantNamePrefix
 */
public Set<Object> getValuesForProperty(String propertyName) {
  return getValues(propertyToConstantNamePrefix(propertyName));
}

代码示例来源:origin: springframework/spring-core

/**
 * Return all values of the group of constants for the
 * given bean property name.
 * @param propertyName the name of the bean property
 * @return the set of values
 * @see #propertyToConstantNamePrefix
 */
public Set getValuesForProperty(String propertyName) {
  return getValues(propertyToConstantNamePrefix(propertyName));
}

相关文章