You are right Andy, but I had probed every option with similar errors.

For instance when I selected PersistentFieldDirectAccessImpl this was
the console output.

[DEFAULT] ERROR: Error getting field:idAtributo in object:com.ecip.ojb.AtributoImpl
org.apache.ojb.broker.metadata.MetadataException: Error getting field:idAtributo in 
object:com.ecip.ojb.AtributoImpl
        at 
org.apache.ojb.broker.metadata.fieldaccess.PersistentFieldDirectAccessImpl.doGet(Unknown
 Source)
        at 
org.apache.ojb.broker.metadata.fieldaccess.AbstractPersistentField.get(Unknown Source)
        at org.apache.ojb.broker.query.QueryByCriteria.buildCriteria(Unknown Source)

....

This is the class, it have private fields and public getters and setters.
I thought that PersistentFieldIntrospectorImpl option was right.

package com.ecip.ojb;
public class AtributoImpl implements Atributo, java.io.Serializable {
          
  private Integer idAtributo;
  private String atributo;
  private String descripcion;
                
  public Integer getIdAtributo() {
    return idAtributo;
  }

  public String getAtributo() {
    return atributo;
  }

  public String getDescripcion() {
   return descripcion;
  }

  public void setIdAtributo(Integer id) {
    this.idAtributo = id;
  }

  public void setAtributo(String atrib) {
    this.atributo = atrib;
  }

  public void setDescripcion(String descrip) {
    this.descripcion = descrip;
  }
}

Is this class OK?
What else should I check in the ojb properties file?


Thanks Andy.



From: Andy Malakov <[EMAIL PROTECTED]>
Subject: IllegarlArgumentException Error
Sent: Tue, 3 Feb 2004 18:08:56 -0500
Subject: IllegarlArgumentException Error


Check your OJB.properties (PersistentFieldClass). You seems to be using 
PersistentFieldIntrospectorImpl which require
JavaBeans-style getters and setters.





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to