All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.ebean.plugin.ExpressionPath Maven / Gradle / Ivy

There is a newer version: 15.8.0
Show newest version
package io.ebean.plugin;

import io.ebean.bean.EntityBean;
import io.ebean.text.StringParser;

/**
 * A dot notation expression path.
 */
public interface ExpressionPath {

  /**
   * Return true if there is a property on the path that is a many property.
   */
  boolean containsMany();

  /**
   * Return the value from a given entity bean.
   */
  Object pathGet(Object bean);

  /**
   * Set a value to the bean for this expression path.
   *
   * @param bean  the bean to set the value on
   * @param value the value to set
   */
  void pathSet(Object bean, Object value);

  /**
   * Convert the value to the expected type.
   * 

* Typically useful for converting strings to the appropriate number type etc. *

*/ Object convert(Object value); /** * Return the default StringParser for the scalar property. */ StringParser stringParser(); /** * Return the underlying JDBC type or 0 if this is not a scalar type. */ int jdbcType(); /** * Return true if this is an ManyToOne or OneToOne associated bean property. */ boolean isAssocId(); /** * Return the Id expression string. *

* Typically used to produce id = ? expression strings. *

*/ String assocIdExpression(String propName, String bindOperator); /** * Return the Id values for the given bean value. */ Object[] assocIdValues(EntityBean bean); /** * Return the underlying bean property. */ Property property(); /** * The ElPrefix plus name. */ String elName(); }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy