congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
java.beans
Code IndexAdd Tabnine to your IDE (free)

How to use java.beans

Best Java code snippets using java.beans (Showing top 20 results out of 12,186)

origin: spring-projects/spring-framework

/**
 * Get the description for a particular attribute.
 * <p>The default implementation returns a description for the operation
 * that is the name of corresponding {@code Method}.
 * @param propertyDescriptor the PropertyDescriptor for the attribute
 * @param beanKey the key associated with the MBean in the beans map
 * of the {@code MBeanExporter}
 * @return the description for the attribute
 */
protected String getAttributeDescription(PropertyDescriptor propertyDescriptor, String beanKey) {
  return propertyDescriptor.getDisplayName();
}
origin: spring-projects/spring-framework

Class<?> getBeanClass() {
  return this.beanInfo.getBeanDescriptor().getBeanClass();
}
origin: spring-projects/spring-framework

/**
 * Create a new MethodInvocationException.
 * @param propertyChangeEvent the PropertyChangeEvent that resulted in an exception
 * @param cause the Throwable raised by the invoked method
 */
public MethodInvocationException(PropertyChangeEvent propertyChangeEvent, Throwable cause) {
  super(propertyChangeEvent, "Property '" + propertyChangeEvent.getPropertyName() + "' threw exception", cause);
}
origin: spring-projects/spring-framework

private boolean hasReadMethodForProperty(BeanInfo beanInfo, String propertyName) {
  for (PropertyDescriptor pd : beanInfo.getPropertyDescriptors()) {
    if (pd.getName().equals(propertyName)) {
      return pd.getReadMethod() != null;
    }
  }
  return false;
}
origin: spring-projects/spring-framework

private boolean hasWriteMethodForProperty(BeanInfo beanInfo, String propertyName) {
  for (PropertyDescriptor pd : beanInfo.getPropertyDescriptors()) {
    if (pd.getName().equals(propertyName)) {
      return pd.getWriteMethod() != null;
    }
  }
  return false;
}
origin: spring-projects/spring-framework

public BeanPropertyHandler(PropertyDescriptor pd) {
  super(pd.getPropertyType(), pd.getReadMethod() != null, pd.getWriteMethod() != null);
  this.pd = pd;
}
origin: spring-projects/spring-framework

private boolean hasIndexedReadMethodForProperty(BeanInfo beanInfo, String propertyName) {
  for (PropertyDescriptor pd : beanInfo.getPropertyDescriptors()) {
    if (pd.getName().equals(propertyName)) {
      if (!(pd instanceof IndexedPropertyDescriptor)) {
        return false;
      }
      return ((IndexedPropertyDescriptor)pd).getIndexedReadMethod() != null;
    }
  }
  return false;
}
origin: spring-projects/spring-framework

private boolean hasIndexedWriteMethodForProperty(BeanInfo beanInfo, String propertyName) {
  for (PropertyDescriptor pd : beanInfo.getPropertyDescriptors()) {
    if (pd.getName().equals(propertyName)) {
      if (!(pd instanceof IndexedPropertyDescriptor)) {
        return false;
      }
      return ((IndexedPropertyDescriptor)pd).getIndexedWriteMethod() != null;
    }
  }
  return false;
}
origin: spring-projects/spring-framework

@ConstructorProperties({"spouse", "otherSpouse", "myAge"})
public ConstructorDependenciesBean(TestBean spouse1, TestBean spouse2, int age) {
  this.spouse1 = spouse1;
  this.spouse2 = spouse2;
  this.age = age;
}
origin: spring-projects/spring-framework

  @Override
  public PropertyDescriptor[] getPropertyDescriptors() {
    try {
      PropertyDescriptor pd = new PropertyDescriptor("value", ValueBean.class);
      pd.setPropertyEditorClass(MyNumberEditor.class);
      return new PropertyDescriptor[] {pd};
    }
    catch (IntrospectionException ex) {
      throw new FatalBeanException("Couldn't create PropertyDescriptor", ex);
    }
  }
}
origin: spring-projects/spring-framework

@Override
public BeanDescriptor getBeanDescriptor() {
  return this.delegate.getBeanDescriptor();
}
origin: spring-projects/spring-framework

  @Override
  public void setValue(Object value) {
    if (value instanceof Integer) {
      super.setValue(new Integer((Integer) value + 1));
    }
  }
});
origin: spring-projects/spring-framework

@Override
public MethodDescriptor[] getMethodDescriptors() {
  return this.delegate.getMethodDescriptors();
}
origin: spring-projects/spring-framework

@Override
public EventSetDescriptor[] getEventSetDescriptors() {
  return this.delegate.getEventSetDescriptors();
}
origin: spring-projects/spring-framework

@Override
public Image getIcon(int iconKind) {
  return this.delegate.getIcon(iconKind);
}
origin: spring-projects/spring-framework

@Override
public int getDefaultPropertyIndex() {
  return this.delegate.getDefaultPropertyIndex();
}
origin: spring-projects/spring-framework

@Override
public int getDefaultEventIndex() {
  return this.delegate.getDefaultEventIndex();
}
origin: spring-projects/spring-framework

@Override
public BeanInfo[] getAdditionalBeanInfo() {
  return this.delegate.getAdditionalBeanInfo();
}
origin: spring-projects/spring-framework

/**
 * Return the name of the affected property, if available.
 */
@Nullable
public String getPropertyName() {
  return (this.propertyChangeEvent != null ? this.propertyChangeEvent.getPropertyName() : null);
}
origin: spring-projects/spring-framework

@SuppressWarnings("unused")
protected String getAttributeDescription(PropertyDescriptor propertyDescriptor) {
  return propertyDescriptor.getDisplayName();
}
java.beans

Most used classes

  • PropertyDescriptor
  • Introspector
  • BeanInfo
  • PropertyChangeEvent
    A "PropertyChange" event gets delivered whenever a bean changes a "bound" or "constrained" property.
  • PropertyChangeSupport
    Manages a list of listeners to be notified when a property changes. Listeners subscribe to be notifi
  • PropertyEditor,
  • IntrospectionException,
  • PropertyEditorManager,
  • PropertyChangeListener,
  • BeanDescriptor,
  • FeatureDescriptor,
  • XMLEncoder,
  • XMLDecoder,
  • PropertyEditorSupport,
  • PropertyVetoException,
  • IndexedPropertyDescriptor,
  • MethodDescriptor,
  • VetoableChangeSupport,
  • EventSetDescriptor
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now