Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Configure DMI to send attributes that are skipped?

    I have a very simple DMI method that returns java.io.File[] of a directory. Is there a way to configure the DMI to pass values that it seems to skip by default, such as file.length(), file.lastModified(). I assume these values do not get passed because Java does not follow the standard get/set property for these values. Am I thus required to wrap a java.io.File with a class that provides the malformed property getters and setters, or is there a way to tell your framework how to retrieve properties that it does not successfully find?

    #2
    You can use dataSourceField.valueXPath to map a DataSourceField to a specific method call - in this case the XPath should be "length()" (just "length" would call try to call getLength()).

    If you are not in the context of a DataSource, you could still have a DataSource just for this purpose and call DataSource.getProperties(fileObject), but this may be just the same amount of work as mapping the property names in some manual way.

    Comment

    Working...
    X