Re: common-compress 1.26.1 not available on Maven

2024-03-08 Thread Niall Pemberton
There is an ongoing vote on the dev list to release Compress 1.26.1. If the
vote is successful, then it should be released in the next few days:

https://lists.apache.org/thread/ymqbqxvft9j209j93l3cgw4z83f2pkr8


Niall

On Fri, 8 Mar 2024 at 15:09, Sahib Yar 
wrote:

> Hello Commons Team,
>
> I can see on github
> <
> https://github.com/apache/commons-compress/commit/01858bbe4ca4fef85bc0fb85cec83915fd963af2
> >,
> COMPRESS-661  was
> fixed in 1.26.1 but it not yet published on Maven
> 
> yet,
> By when will this be published on Maven ?
>
> Sahib Yar
>
> Tech Lead at securiti
>
> +92 336 6037321 <+92+336+6037321>
>
> sahib@securiti.ai
>
> See Your DataCommand.Center
> <
> https://datacommand.center/?utm_source=email_signature_medium=banner_campaign=datacommandcenter
> >
> <
> https://datacommand.center/?utm_source=email_signature_medium=banner_campaign=datacommandcenter
> >
>
> *Confidentiality Notice:* The content of this message, including any
> attachments, is confidential. The information contained herein is for
> informational purposes only and should not be construed as legal or tax
> advice. It is intended to be read only by the individual or entity to whom
> it is addressed. If you are not the intended recipient, please notify the
> sender by replying to this message and delete the material immediately from
> your system. Any further use, dissemination, distribution or reproduction
> of this message is strictly prohibited.
>
> --
>
>
> See Your DataCommand.Center
> <
> https://datacommand.center/?utm_source=email_signature_medium=banner_campaign=datacommandcenter
> >
>
> <
> https://datacommand.center/?utm_source=email_signature_medium=banner_campaign=datacommandcenter
> >
>
> --
> Confidentiality Notice: The content of this message, including any
> attachments, is confidential. The information contained herein is for
> informational purposes only and should not be construed as legal or tax
> advice. It is intended to be read only by the individual or entity to whom
> it is addressed. If you are not the intended recipient, please notify the
> sender by replying to this message and delete the material immediately
> from
> your system. Any further use, dissemination, distribution or reproduction
> of this message is strictly prohibited.
>


Re: Updating Apache Commons DBCP 2.10.0

2023-09-28 Thread Niall Pemberton
On Thu, 28 Sep 2023 at 14:47, Niall Pemberton 
wrote:

> On Tue, 26 Sep 2023 at 21:00, Phil Steitz  wrote:
>
>> On Tue, Sep 26, 2023 at 4:50 AM Gary Gregory 
>> wrote:
>>
>> > (Let's stop high jacking the announcement thread.)
>> >
>>
>> Agreed.  Sorry about that.
>>
>> >
>> > In the future, FYI, I plan on supporting both Java and Jakarta by
>> splitting
>> > DBCP into a multi-module Maven project. I'm not sure exactly when but
>> it's
>> > on my to do list.
>> >
>>
>> That sounds good.  But we may need to do something before that to restore
>> backward compatibility (if there is in fact a problem).  The build error
>> that Greg reports below is somehow related to the Commons Parent 62
>> version.  If I back rev Commons Parent to version 60 and revert the JTA
>> spec jar change (per below), the build works.  (Greg - can you try that -
>> just change Commons Parent version to 60 along with the change below).
>>
>> Alternatively, maybe there is some other workaround to avoid the conflict
>> that Greg is reporting.  I am not sure if there is in fact a backward
>> compat issue here.  Any better ideas?
>>
>> One more thing is the EPL/GPL license on the Jakarta jars.   Have these
>> been cleared for use (as dependencies) in ASF projects?
>
>
> The Eclipse Public Licenses (EPL 1.0 and EPL 2.0) are both listed as
> “Category B” licenses, which means they are fine for binary releases:
>
> https://www.apache.org/legal/resolved.html
>
> Do we need some
>> kind of notice for this?
>
>
> Are the Jakarta jars being shipped in the binary distro or are they just a
> dependency in the pom? If they’re in the release distro then yes otherwise
> no:
>
> https://infra.apache.org/licensing-howto.html
>

Aliso, I’m not familiar with the move of the specification to Jakarta - can
there be other implementations of the Spec or is this jar the only possible
source of the API? If there could be other implementations of the Spec,
then you could mark the scope as “provided” - which would mean users would
have to specify the API dependency which could be Jakarta or another
implementation. “Provided” has the same effect as “Optional”.

Niall

<https://infra.apache.org/licensing-howto.html>
>
> Niall
>
>
>
>>
>> Phil
>>
>> >
>> > Gary
>> >
>> >
>> >
>> > On Tue, Sep 26, 2023, 5:00 AM Greg Huber  wrote:
>> >
>> > > If I am understanding this correctly, I replace
>> > >
>> > > 
>> > > 
>> > >   jakarta.transaction
>> > >   jakarta.transaction-api
>> > >   1.3.1
>> > > 
>> > >
>> > > with
>> > >
>> > > 
>> > > org.apache.geronimo.specs
>> > > geronimo-jta_1.1_spec
>> > > 1.1.1
>> > > true
>> > > 
>> > >
>> > > in the source of 2.10.0 pom.xml and then mvn clean package.
>> > >
>> > > I get this error
>> > >
>> > > [ERROR] Failed to execute goal
>> > > org.moditect:moditect-maven-plugin:1.0.0.Final:add-module-info
>> > > (add-module-infos) on project commons-dbcp2: Execution
>> add-module-infos
>> > > of goal org.moditect:moditect-maven-plugin:1.0.0.Final:add-module-info
>> > > failed: No assignedModuleName provided for jar with invalid module
>> name:
>> > >
>> >
>> ~/.m2/repository/org/apache/geronimo/specs/geronimo-jta_1.1_spec/1.1.1/geronimo-jta_1.1_spec-1.1.1.jar
>> > >
>> > > -> [Help 1]
>> > >
>> > > #
>> > >
>> > >
>> > > I did a diff of my apps /lib folder between the 2.10.0 and 2.9.0
>> > >
>> > > Only in ~/downloads/commons-dbcp2-2.10.0-src/target/lib.9:
>> > > commons-dbcp2-2.9.0.jar
>> > > Only in ~/downloads/commons-dbcp2-2.10.0-src/target/lib.10:
>> > > commons-dbcp2-2.10.0.jar
>> > >
>> > > Only in ~/downloads/commons-dbcp2-2.10.0-src/target/lib.9:
>> > > commons-pool2-2.10.0.jar
>> > > Only in ~/downloads/commons-dbcp2-2.10.0-src/target/lib.10:
>> > > commons-pool2-2.11.1.jar
>> > >
>> > > Only in ~/downloads/commons-dbcp2-2.10.0-src/target/lib.9:
>> > > jakarta.transaction-api-2.0.1.jar
>> > > Only in ~/downloads/commons-dbcp2-2.10.0-src/target/lib.10:
>> > > jakarta.transaction-api-1.3.1.jar
>> >

Re: Updating Apache Commons DBCP 2.10.0

2023-09-28 Thread Niall Pemberton
On Tue, 26 Sep 2023 at 21:00, Phil Steitz  wrote:

> On Tue, Sep 26, 2023 at 4:50 AM Gary Gregory 
> wrote:
>
> > (Let's stop high jacking the announcement thread.)
> >
>
> Agreed.  Sorry about that.
>
> >
> > In the future, FYI, I plan on supporting both Java and Jakarta by
> splitting
> > DBCP into a multi-module Maven project. I'm not sure exactly when but
> it's
> > on my to do list.
> >
>
> That sounds good.  But we may need to do something before that to restore
> backward compatibility (if there is in fact a problem).  The build error
> that Greg reports below is somehow related to the Commons Parent 62
> version.  If I back rev Commons Parent to version 60 and revert the JTA
> spec jar change (per below), the build works.  (Greg - can you try that -
> just change Commons Parent version to 60 along with the change below).
>
> Alternatively, maybe there is some other workaround to avoid the conflict
> that Greg is reporting.  I am not sure if there is in fact a backward
> compat issue here.  Any better ideas?
>
> One more thing is the EPL/GPL license on the Jakarta jars.   Have these
> been cleared for use (as dependencies) in ASF projects?


The Eclipse Public Licenses (EPL 1.0 and EPL 2.0) are both listed as
“Category B” licenses, which means they are fine for binary releases:

https://www.apache.org/legal/resolved.html

Do we need some
> kind of notice for this?


Are the Jakarta jars being shipped in the binary distro or are they just a
dependency in the pom? If they’re in the release distro then yes otherwise
no:

https://infra.apache.org/licensing-howto.html

Niall



>
> Phil
>
> >
> > Gary
> >
> >
> >
> > On Tue, Sep 26, 2023, 5:00 AM Greg Huber  wrote:
> >
> > > If I am understanding this correctly, I replace
> > >
> > > 
> > > 
> > >   jakarta.transaction
> > >   jakarta.transaction-api
> > >   1.3.1
> > > 
> > >
> > > with
> > >
> > > 
> > > org.apache.geronimo.specs
> > > geronimo-jta_1.1_spec
> > > 1.1.1
> > > true
> > > 
> > >
> > > in the source of 2.10.0 pom.xml and then mvn clean package.
> > >
> > > I get this error
> > >
> > > [ERROR] Failed to execute goal
> > > org.moditect:moditect-maven-plugin:1.0.0.Final:add-module-info
> > > (add-module-infos) on project commons-dbcp2: Execution add-module-infos
> > > of goal org.moditect:moditect-maven-plugin:1.0.0.Final:add-module-info
> > > failed: No assignedModuleName provided for jar with invalid module
> name:
> > >
> >
> ~/.m2/repository/org/apache/geronimo/specs/geronimo-jta_1.1_spec/1.1.1/geronimo-jta_1.1_spec-1.1.1.jar
> > >
> > > -> [Help 1]
> > >
> > > #
> > >
> > >
> > > I did a diff of my apps /lib folder between the 2.10.0 and 2.9.0
> > >
> > > Only in ~/downloads/commons-dbcp2-2.10.0-src/target/lib.9:
> > > commons-dbcp2-2.9.0.jar
> > > Only in ~/downloads/commons-dbcp2-2.10.0-src/target/lib.10:
> > > commons-dbcp2-2.10.0.jar
> > >
> > > Only in ~/downloads/commons-dbcp2-2.10.0-src/target/lib.9:
> > > commons-pool2-2.10.0.jar
> > > Only in ~/downloads/commons-dbcp2-2.10.0-src/target/lib.10:
> > > commons-pool2-2.11.1.jar
> > >
> > > Only in ~/downloads/commons-dbcp2-2.10.0-src/target/lib.9:
> > > jakarta.transaction-api-2.0.1.jar
> > > Only in ~/downloads/commons-dbcp2-2.10.0-src/target/lib.10:
> > > jakarta.transaction-api-1.3.1.jar
> > >
> > >
> > > If I copy lib.9: jakarta.transaction-api-2.0.1.jar to replace the
> > > lib.10: jakarta.transaction-api-1.3.1.jar class
> > > ThreadLocalSessionContextNoAutoClose compiles and works.
> > >
> > > Cheers Greg
> > >
> > > On 25/09/2023 18:49, Phil Steitz wrote:
> > > > Thanks, Greg.  I assume that dependency was there and working with
> DBCP
> > > > 2.9, correct?
> > > >
> > > > Can you try reverting the pom change above, replacing the
> > > > Jakarta transactions reference with
> > > >
> > > > 
> > > >org.apache.geronimo.specs
> > > >geronimo-jta_1.1_spec
> > > >1.1.1
> > > >true
> > > > 
> > > >
> > > > Then recompile DBCP from 2.10 sources and test (just use mvn clean
> > > package
> > > > from the root of an extract of the source distribution).
> > > >
> > > > Phil
> > > >
> > > > On Mon, Sep 25, 2023 at 12:44 AM Greg Huber 
> > wrote:
> > > >
> > > >>>> does your code maybe bring in the 2.0 jakarta spec jar?
> > > >>
> > > >> I do have :
> > > >>
> > > >> jakarta.transaction-api-2.0.1.jar
> > > >>
> > > >> which comes from hibernate-core 6.3.1.Final.
> > > >>
> > > >>
> > > >>
> > > >> ###
> > > >>
> > > >> Using eclipse here are the errors
> > > >>
> > > >> The project was not built since its build path is incomplete. Cannot
> > > >> find the class file for jakarta.transaction.Synchronization. Fix the
> > > >> build path then try building this project
> > > >>
> > > >> The type jakarta.transaction.Synchronization cannot be resolved. It
> is
> > > >> indirectly referenced from required type
> > > >> org.hibernate.context.internal.ThreadLocalSessionContext.CleanupSync
> > > >>
> > > 

Re: [ jexl3 ]

2023-01-09 Thread Niall Pemberton
I can see the *ASTFunctionNode *class file in the
*org.apache.commons.jexl3.parser* package of the *commons-jexl3-3.2.1.jar*
file.

Can you provide more details?

   - what specific version of jexl are you using?
   - can you provide the fully qualified name of the *ASTFunctionNode *class
   file that you're missing (i.e. including the package name)
   - can you provide the full class path for your application?
   - can you provide any stack trace for where its failing with the missing
   class?

Niall

On Mon, 9 Jan 2023 at 20:30, Stefan Tudora 
wrote:

> Hello,
>
>
>
> My name is Stefan and I am currently working for a small software
> development company. We have need of an expression engine for our current
> application and saw that Apache offers Jexl3. I had some issues trying to
> get the engine up and running for it seems that some files are dependent on
> missing classes such as 'ASTFunctionNode'.
> I saw that some of the missing files are present in older versions such as
> 1.1 and 2.1, but even after importing the missing classes I still have
> dependencies issues. Is there something I am missing or not doing properly?
>
>
> Kind regards,
>
> Stefan Tudora
>


Re: [VALIDATOR] JavaScript port of commons-validator

2015-12-02 Thread Niall Pemberton
On Sun, Nov 29, 2015 at 5:56 PM, Danny Leshem <dles...@gmail.com> wrote:

> Accept this as what? It's not a pull request, just an FYI.
>

Ah, my mistake, I didn't read carefully enough. Assumed you were proposing
this for commons, rather than just doing publicity.

Niall


>
> Either way, as far as I know the JavaScript code that was removed in 1.5.0
> did not handle email / domain validation.
> On Nov 29, 2015 7:20 PM, "Niall Pemberton" <niall.pember...@gmail.com>
> wrote:
>
> > On Sat, Nov 28, 2015 at 2:11 PM, Danny Leshem <dles...@gmail.com> wrote:
> >
> > > *TL;DR-*
> > > commons-validator-js <https://github.com/wix/commons-validator-js> is
> a
> > > partial JavaScript port of commons-validator (currently EmailValidator
> > and
> > > DomainValidator).
> > >
> >
> > I think its unlikely the current people working on validator will accept
> > this as validator used to have javascript validation and its just been
> > removed from the latest (1.5.0) release:
> >
> > https://issues.apache.org/jira/browse/VALIDATOR-371
> >
> >
> https://commons.apache.org/proper/commons-validator/changes-report.html#a1.5.0
> >
> > Niall
> >
> >
> >
> > >
> > > *Long version-*
> > > commons-validator's EmailValidator is by far the best and most
> > > comprehensive email validator out there.
> > >
> > > Unfortunately, there's no equivalent JavaScript implementation.
> > > Specifically, I couldn't find a JavaScript email validation library
> that
> > A)
> > > works offline, and B) validates top level domains (e.g. fails
> > > "chuck.nor...@gmail.con").
> > >
> > > Introducing: commons-validator-js, a JavaScript version of
> EmailValidator
> > > and DomainValidator, each accompanied by a complete test case.
> > >
> > > The only challenge was working around some issues with JavaScript's
> > regexp
> > > implementation, e.g. no support for lookbehind or "\p{...}".
> Eventually I
> > > commented-out 2-3 tests that still fail, but these were edge cases that
> > > didn't really bother me.
> > >
> >
>


Re: [VALIDATOR] JavaScript port of commons-validator

2015-11-29 Thread Niall Pemberton
On Sat, Nov 28, 2015 at 2:11 PM, Danny Leshem  wrote:

> *TL;DR-*
> commons-validator-js  is a
> partial JavaScript port of commons-validator (currently EmailValidator and
> DomainValidator).
>

I think its unlikely the current people working on validator will accept
this as validator used to have javascript validation and its just been
removed from the latest (1.5.0) release:

https://issues.apache.org/jira/browse/VALIDATOR-371
https://commons.apache.org/proper/commons-validator/changes-report.html#a1.5.0

Niall



>
> *Long version-*
> commons-validator's EmailValidator is by far the best and most
> comprehensive email validator out there.
>
> Unfortunately, there's no equivalent JavaScript implementation.
> Specifically, I couldn't find a JavaScript email validation library that A)
> works offline, and B) validates top level domains (e.g. fails
> "chuck.nor...@gmail.con").
>
> Introducing: commons-validator-js, a JavaScript version of EmailValidator
> and DomainValidator, each accompanied by a complete test case.
>
> The only challenge was working around some issues with JavaScript's regexp
> implementation, e.g. no support for lookbehind or "\p{...}". Eventually I
> commented-out 2-3 tests that still fail, but these were edge cases that
> didn't really bother me.
>


Re: OSGI - missing imported package=org.apache.commons.collections

2012-02-19 Thread Niall Pemberton
Collections 3.2.0 doesn't have the OSGi meta data. Collections 3.2.1
was released to rectify this:

http://commons.apache.org/collections/release_3_2_1.html

Niall

On Fri, Feb 17, 2012 at 4:05 PM, rcbandit peter.pen...@gmail.com wrote:
 I'm trying to create very simple OSGI bundle with Circular FIFO Buffer. This
 is the complete source code:  http://www.2shared.com/file/TkLeBBO2/test.html

 I created this simple java class:

    package com.sh_2.test;

    import org.apache.commons.collections.BufferUtils;
    import org.apache.commons.collections.buffer.CircularFifoBuffer;

    public class Buffer {

          Buffer fifo = (Buffer) BufferUtils.synchronizedBuffer(new
 CircularFifoBuffer(200));

    }

 I imported dependency package org.apache.commons.collections. I successfully
 compiled the code with Netbeans. When I tried to deploy the bundle on
 Glassfish application server I get this error:


    Feb 17, 2012 5:40:22 PM
 com.sun.enterprise.admin.launcher.GFLauncherLogger info
    INFO: JVM invocation command line:
    /opt/jdk1.7.0_01/bin/java
    -cp
    /opt/glassfish3/glassfish/modules/glassfish.jar
    -XX:+UnlockDiagnosticVMOptions
    -XX:MaxPermSize=192m
    -XX:NewRatio=2
    -Xmx512m
    -client
    -javaagent:/opt/glassfish3/glassfish/lib/monitor/flashlight-agent.jar
    -Dfelix.fileinstall.disableConfigSave=false

 -Djavax.net.ssl.keyStore=/opt/glassfish3/glassfish/domains/domain1/config/keystore.jks
    -Djava.awt.headless=true
    -Dfelix.fileinstall.poll=5000

 -Djava.endorsed.dirs=/opt/glassfish3/glassfish/modules/endorsed:/opt/glassfish3/glassfish/lib/endorsed
    -Dfelix.fileinstall.bundles.startTransient=true

 -Djavax.net.ssl.trustStore=/opt/glassfish3/glassfish/domains/domain1/config/cacerts.jks
    -Dcom.sun.enterprise.security.httpsOutboundKeyAlias=s1as
    -DANTLR_USE_DIRECT_CLASS_LOADING=true

 -Djava.security.auth.login.config=/opt/glassfish3/glassfish/domains/domain1/config/login.conf
    -Dgosh.args=--nointeractive
    -Dosgi.shell.telnet.maxconn=1
    -Djdbc.drivers=org.apache.derby.jdbc.ClientDriver
    -Dfelix.fileinstall.dir=/opt/glassfish3/glassfish/modules/autostart/
    -Dosgi.shell.telnet.port=

 -Djava.security.policy=/opt/glassfish3/glassfish/domains/domain1/config/server.policy
    -Dfelix.fileinstall.log.level=2

 -Dcom.sun.enterprise.config.config_environment_factory_class=com.sun.enterprise.config.serverbeans.AppserverConfigEnvironmentFactory
    -Dosgi.shell.telnet.ip=127.0.0.1
    -Dcom.sun.aas.instanceRoot=/opt/glassfish3/glassfish/domains/domain1
    -Dcom.sun.aas.installRoot=/opt/glassfish3/glassfish

 -Djava.ext.dirs=/opt/jdk1.7.0_01/lib/ext:/opt/jdk1.7.0_01/jre/lib/ext:/opt/glassfish3/glassfish/domains/domain1/lib/ext
    -Dfelix.fileinstall.bundles.new.start=true

 -Dorg.glassfish.additionalOSGiBundlesToStart=org.apache.felix.shell,org.apache.felix.gogo.runtime,org.apache.felix.gogo.shell,org.apache.felix.gogo.command,org.apache.felix.fileinstall

 -Djava.library.path=/opt/glassfish3/glassfish/lib:/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/jre/lib/amd64/server:/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/jre/lib/amd64:/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/lib/amd64:/usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib
    com.sun.enterprise.glassfish.bootstrap.ASMain
    -domainname
    domain1
    -asadmin-args

 --host,,,localhost,,,--port,,,4848,,,--secure=false,,,--terse=false,,,--echo=false,,,--interactive=true,,,start-domain,,,--verbose=false,,,--debug=false,,,--domaindir,,,/opt/glassfish3/glassfish/domains,,,domain1
    -instancename
    server
    -verbose
    false
    -debug
    false
    -asadmin-classpath
    /opt/glassfish3/glassfish/modules/admin-cli.jar
    -asadmin-classname
    com.sun.enterprise.admin.cli.AsadminMain
    -upgrade
    false
    -type
    DAS
    -domaindir
    /opt/glassfish3/glassfish/domains/domain1
    -read-stdin
    true
    Feb 17, 2012 5:40:22 PM
 com.sun.enterprise.admin.launcher.GFLauncherLogger info
    INFO: Successfully launched in 35 msec.

 [#|2012-02-17T17:40:32.867+0200|INFO|null|null|_ThreadID=1;_ThreadName=Thread-2;|Running
 GlassFish Version: GlassFish Server Open Source Edition 3.1.1 (build 12)|#]


 [#|2012-02-17T17:40:32.868+0200|WARNING|null|null|_ThreadID=1;_ThreadName=Thread-2;|Record
 begin marker is not a proper value so using default.|#]


 [#|2012-02-17T17:40:32.868+0200|WARNING|null|null|_ThreadID=1;_ThreadName=Thread-2;|Record
 end marker is not a proper value so using default.|#]


 [#|2012-02-17T17:40:32.868+0200|WARNING|null|null|_ThreadID=1;_ThreadName=Thread-2;|Log
 Format field separator is not a character so using default.|#]


 [#|2012-02-17T17:40:33.237+0200|INFO|glassfish3.1.1|org.glassfish.ha.store.spi.BackingStoreFactoryRegistry|_ThreadID=1;_ThreadName=Thread-2;|Registered
 org.glassfish.ha.store.adapter.cache.ShoalBackingStoreProxy for
 persistence-type = replicated in BackingStoreFactoryRegistry|#]


 

Re: [beanutils] Issue with ContextClassLoaderLocal class.

2011-05-24 Thread Niall Pemberton
On Tue, May 24, 2011 at 1:55 PM, Rammohan Natarajan
rammohan.natara...@tcs.com wrote:
 Hi,

 We are working on migrating a J2EE application from WAS6.1 to JBoss EAP 5.0. 
 For unmarshalling of some custom XML we make use of commons-beanutils-1.8.3 
 within this application; and in the process, we have defined a custom type 
 converter for one of the XML tags.
 The registration of this converter happens in one EJB module within our EAR, 
 whereas theactual XML parsing occurs in another EJB module within the same 
 EAR.
 The org.apache.commons.beanutils.ContextClassLoaderLocal class ties 'global' 
 variables to a classloader instance in a map to ensure data isolation even if 
 the variable is referenced by multiple components running within a container.
 Here is the relevant code snippet from its get() method:

    ClassLoader contextClassLoader = 
 Thread.currentThread().getContextClassLoader();
    if (contextClassLoader != null)
    {
        Object value = valueByClassLoader.get(contextClassLoader);
        if ((value == null)  
 !valueByClassLoader.containsKey(contextClassLoader))
        {
            value = initialValue();
            valueByClassLoader.put(contextClassLoader, value);
        }
    return value;
    }

 After all that background information, here is the problem:
 During the converter registration process, a BeanUtilsBean instance is 
 maintained in the ContextClassLoaderLocal map against the classloader of the 
 registration EJB module.
 During the parsing process, this map is queried to retreive the same 
 BeanUtilsBean instance, using the classloader of the parsing EJB module as 
 the key. In Websphere Application server, the classloader instance for the 
 registration module and the parser module are both same; the correct 
 BeanUtilsBean instance is retreived and processing proceeds as expected. 
 However, in JBoss EAP 5.0, the two classloader instances are different so 
 that the parser module fails to retreive the value from the map.
 Is this a problem with beanutils' design or an issue with JBoss?

I think you need to register the converter in the module its used in -
i.e. your parsing EJB module

Niall

 Please let me know if I am missing something or if additional details are 
 required.
 Thanks in advance.
 N.Rammohan.
 =-=-=
 Notice: The information contained in this e-mail
 message and/or attachments to it may contain
 confidential or privileged information. If you are
 not the intended recipient, any dissemination, use,
 review, distribution, printing or copying of the
 information contained in this e-mail message
 and/or attachments to it are strictly prohibited. If
 you have received this communication in error,
 please notify us by reply e-mail or telephone and
 immediately and permanently delete the message
 and any attachments. Thank you




 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [io] Tailer returning partial lines returned when EOF before newline

2011-05-24 Thread Niall Pemberton
On Tue, May 24, 2011 at 6:32 PM, frankgrimes97 frankgrime...@gmail.com wrote:
 Hi All,

 We are using org.apache.commons.io.input.Tailer to process log files for
 insertion into a database.

 What we are seeing is that occasionally a line fails to process because it
 is incomplete.
 In reviewing the code, it appears that Tailer.readLines delegates to
 java.io.RandomAccessFile.readLine which returns a partial line if EOF is
 reached.

 Shouldn't Tailer be providing a guarantee of complete lines?
 Should we create a bug report for this?

 FYI, we are using 1.6.0_15 on Linux.

Sure

https://issues.apache.org/jira/browse/IO

Niall

 Thanks,

 Frank Grimes


-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [io] Apache Tailer prevents log4j from creating backup files?

2011-04-08 Thread Niall Pemberton
On Thu, Apr 7, 2011 at 6:04 PM, Hemal Pandya hemal.pan...@gmail.com wrote:
 Hello,

 I am trying to use Apache Tailer for a utility that processes log file
 entries.

 My log4j configuration creates backup files when the max file size has been
 reached. It seems the Tailer is correctly handling the file roll over
 without missing any lines but log4j is no longer creating the .1 etc back-up
 files. I suspect it is a conflict between with how Tailer has opened the
 file and how log4j created backups.

 Does anybody else have similar experience? Is it a usage error on my part?

 Thanks in advance for any answers, pointers or suggestions.


Can you create an issue in JIRA with all the details, so that this
doesn't get lost or forgotten.

http://commons.apache.org/io/issue-tracking.html

thanks

Niall

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: Re: [beanutils] BeanUtilsBean#setProperty() behaviour in 1.7 and 1.8

2011-03-11 Thread Niall Pemberton
2011/3/11 Björn Moritz bjoern.mor...@gmail.com:
 Wed, 09 Mar 2011 15:38:23 -0800

 2011/3/7 Björn Moritz bjoern.mor...@gmail.com:
  Hello,
 
  is there a reason for BeanUtilsBean#setProperty() in line 968 not
  using the PropertyType of the current PropertyDescriptor as the type
  of class to convert to, but instead the class of the value to be
  converted?
  Until beanutils 1.7 a String array was converted to a string using the
  first element of the array; since 1.8 the string array is converted to
  a string using the toString method of the array (as the destination
  type is now an array type).
  Why can't we use the property descriptor for these mapped properties, too?

 BeanUtils (uniquely) has the concept of a MappedPropertyDescriptor
 like the IndexedPropertyDescriptor, so that if you have acessor
 methods in your bean with a key parameter, then it assumes it is
 accessing an underlying Map. In that scenario it does indeed use the
 descriptor to determine the type. However if it has  a Map property
 (i.e. has methods that set/return a Map) then there is no way to
 determine the type. By the time it reaches the line number you quote,
 then its in the later scenario and the type can't be determined -
 since the descriptor type should be a Map.

 Niall

 Hi Niall,

 thank you for your answer.
 So you're suggesting to replace in our beans code like this:

 public SortedMapString, String getWidth() {
     return widthMap;
 }

 public void setWidth(SortedMapString, String widthMap) {
  this.widthMap= widthMap;
 }

 with:

 public String getWidth(String index) {
        return widthMap.get(index);
 }

 public void setWidth(String index, String width) {
     widthMap.put(index, width);
 }

 Then BeanUtils will use a MappedPropertyDescriptor and map our values 
 correctly?

Yes, but I think you could add those methods (rather than replace) and
it should work.

Niall

 Björn



  Regards,
 
  Björn
 
  -
  To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
  For additional commands, e-mail: user-h...@commons.apache.org
 
 

 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org

 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [beanutils] BeanUtilsBean#setProperty() behaviour in 1.7 and 1.8

2011-03-09 Thread Niall Pemberton
2011/3/7 Björn Moritz bjoern.mor...@gmail.com:
 Hello,

 is there a reason for BeanUtilsBean#setProperty() in line 968 not
 using the PropertyType of the current PropertyDescriptor as the type
 of class to convert to, but instead the class of the value to be
 converted?
 Until beanutils 1.7 a String array was converted to a string using the
 first element of the array; since 1.8 the string array is converted to
 a string using the toString method of the array (as the destination
 type is now an array type).
 Why can't we use the property descriptor for these mapped properties, too?

BeanUtils (uniquely) has the concept of a MappedPropertyDescriptor
like the IndexedPropertyDescriptor, so that if you have acessor
methods in your bean with a key parameter, then it assumes it is
accessing an underlying Map. In that scenario it does indeed use the
descriptor to determine the type. However if it has  a Map property
(i.e. has methods that set/return a Map) then there is no way to
determine the type. By the time it reaches the line number you quote,
then its in the later scenario and the type can't be determined -
since the descriptor type should be a Map.

Niall


 Regards,

 Björn

 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



[ANNOUNCE] Commons Lang 2.6 released

2011-01-17 Thread Niall Pemberton
The Apache Commons team is pleased to announce the release of Commons Lang 2.6

Details of the changes and bug fixes in this release can be found in
the release notes:
  http://commons.apache.org/lang/upgradeto2_6.html

For information on Commons Lang please visit the Lang website:
  http://commons.apache.org/lang/

Commons Lang can be downloaded from the following page:
  http://commons.apache.org/lang/download_lang.cgi


Niall
on behalf of the Apache Commons community

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [Lang] Null safe date comparisson

2011-01-06 Thread Niall Pemberton
On Thu, Jan 6, 2011 at 6:47 PM, Gary Gregory
ggreg...@seagullsoftware.com wrote:
 -Original Message-
 From: Niall Pemberton [mailto:niall.pember...@gmail.com]
 Sent: Thursday, January 06, 2011 13:28
 To: Commons Users List
 Subject: Re: [Lang] Null safe date comparisson

 On Thu, Jan 6, 2011 at 4:38 PM, sebb seb...@gmail.com wrote:
  On 6 January 2011 16:31, Ludwig Magnusson lud...@itcatapult.com wrote:
  Hi!
 
  I'm looking for a way to do null safe date comparison. Something like:
 
 
 
  public static boolean isBefore(Date first, Date second);
 
 
 
  The method would handle null in an appropriate way.
 
  What do you mean by appropriate?
 
  Does null mean beginning of time, or end of time, or now, or Y2K or
  something else?
 
  How does one choose the default?

 I was thinking it would be usefule to have a null safe compare method
 to ObjectUtils - something like

     public static int compare(Comparable c1, Comparable c2) {
         return compare(c1, c2, false);
     }
     public static int compare(Comparable c1, Comparable c2, boolean
 nullMoreThan) {
         int result = 0;
         if ((c1 == null) || (c2 == null)) {
             if (nullMoreThan) {
                 result = (c1 == null ? 1 : 0) - (c2 == null ? 1 : 0);
             } else {
                 result = (c1 == null ? -1 : 0) - (c2 == null ? -1 : 0);
             }
         } else {
             result = c1.compareTo(c2);
         }
         return result;
     }

 As dates implement comparable it would work for them as well

 Niall

 +1 That would be useful. Same for equals?

Its there already!

http://tinyurl.com/36e6oes

Niall

 Gary


  I haven't found any method like that in DateUtils.
 
  Is there one somewhere?
 
  /Ludwig
 
 

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [Lang] Null safe date comparisson

2011-01-06 Thread Niall Pemberton
On Thu, Jan 6, 2011 at 6:27 PM, Niall Pemberton
niall.pember...@gmail.com wrote:
 On Thu, Jan 6, 2011 at 4:38 PM, sebb seb...@gmail.com wrote:
 On 6 January 2011 16:31, Ludwig Magnusson lud...@itcatapult.com wrote:
 Hi!

 I'm looking for a way to do null safe date comparison. Something like:



 public static boolean isBefore(Date first, Date second);



 The method would handle null in an appropriate way.

 What do you mean by appropriate?

 Does null mean beginning of time, or end of time, or now, or Y2K or
 something else?

 How does one choose the default?

 I was thinking it would be usefule to have a null safe compare method
 to ObjectUtils - something like

    public static int compare(Comparable c1, Comparable c2) {
        return compare(c1, c2, false);
    }
    public static int compare(Comparable c1, Comparable c2, boolean
 nullMoreThan) {
        int result = 0;
        if ((c1 == null) || (c2 == null)) {
            if (nullMoreThan) {
                result = (c1 == null ? 1 : 0) - (c2 == null ? 1 : 0);
            } else {
                result = (c1 == null ? -1 : 0) - (c2 == null ? -1 : 0);
            }
        } else {
            result = c1.compareTo(c2);
        }
        return result;
    }

 As dates implement comparable it would work for them as well

I've added this:

https://issues.apache.org/jira/browse/LANG-667
http://svn.apache.org/viewvc?view=revisionrevision=1056124

 Niall

 I haven't found any method like that in DateUtils.

 Is there one somewhere?

 /Ludwig





 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org




-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



[ANNOUNCE] Commons IO 2.0.1 released

2011-01-01 Thread Niall Pemberton
The Apache Commons team is pleased to announce the release of Commons IO 2.0.1

This release contains a small number of bug fixes for the 2.0 release
- full details of which can be found in the release notes:
   http://commons.apache.org/io/upgradeto2_0_1.html

For information on Commons IO please visit the IO website:
   http://commons.apache.org/io/

Commons IO can be downloaded from the following page:
   http://commons.apache.org/io/download_io.cgi


Niall
on behalf of the Apache Commons community

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [io] It seems not possible to control order in which FileAlterationObserver triggers FileAlterationListener when more than one file alteration was detected

2010-12-31 Thread Niall Pemberton
On Tue, Dec 28, 2010 at 10:51 AM, Damien Tacheron dtache...@sqli.com wrote:
 Hi,

 i'm not english native, so i'll do my best.

 i need to be triggered by FileAlterationListener for file creation or file
 update, based a timeline :
 - first the first file which was created or updated
 - second, the second fil which was created or updated
 and so on

 but, it seems that trigerring was done in alphabetical order and i dont' find
 anything to control this.

You are correct - there is no way to do this.

FileAlterationObserver works by comparing the previous state of a
directory structure with the current state and in order to *match*
files it sorts the contents of each directory on file name to
determine if a file previously existed or has been added or deleted.
As a consequence of that is the behaviour you see - i.e. triggering in
alphabetical order.

There is no straight forward way to do what you want. The file events
would need to be *buffered* in some way and then sorted into time
order before firing the listeners.

Niall

 any idea ?

 Best regards

  *Damien Tacheron*
 Chef de projet
 --
 SQLI Paris
 standard : 01 55 93 26 00
 ligne directe : 01 55 93 02 51
 dtache...@hotmail.fr


-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [IO] tailer sample code

2010-11-10 Thread Niall Pemberton
2010/11/10 Sébastien Roux roux.sebast...@gmail.com:
 I'm not a Java specialist but quite curious about the new tailer classes in
 commons IO 2.0.

 Now what does this mean : TailerListener listener = ...

Its just an abbreviation to show the line is not complete.

You have to create your own TailerListener implementation which does
whatever you want with the lines added to the file. So for example you
could do something like the following:

/**
 * TailerListener implementation.
 */
public class ShowLinesListener extends TailerListenerAdapter {
@Override
public void handle(String line) {
System.out.println(line);
}
}

Then create the Tailer with your implementation:

TailerListener listener = new ShowLinesListener();
Tailer tailer = Tailer.create(file, listener, delay);

http://commons.apache.org/io/api-release/org/apache/commons/io/input/Tailer.html

Niall

 I mean what I am supposed to put after the equal? Would you have a quick
 example regarding basic file tailing implementation?

 I also checked this without getting the picture =
 http://permalink.gmane.org/gmane.comp.jakarta.commons.scm/9636

 Many thanks for any guidance you may provide.

 Sébastien Roux
 mail:  roux.sebast...@gmail.com


-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [io] is 2.0 on Maven?

2010-10-29 Thread Niall Pemberton
The reason the existing groupId was used was because it was a compatible
release and so far in Commons we have not collectively or individually
decided to relocate artifacts in that scenario.

Its probably a discussion we should have over on d...@. Although it will
create issues for users relocating all our artifacts (and adding redirection
poms) - it is something that can be resolved by a user (AFAIK they just have
to remove old artifacts from the local repo). I'm starting to think we
should just bite the bullet and do it.

Niall


On Fri, Oct 29, 2010 at 1:02 PM, James Carman ja...@carmanconsulting.comwrote:

 The confusion is probably because most folks assume we would be using
 the new group id which commons io (for some strange reason) did not.

 On Fri, Oct 29, 2010 at 7:51 AM, Niall Pemberton
 niall.pember...@gmail.com wrote:
  Its been there since the day after it was released - see:
 
  http://repo1.maven.org/maven2/commons-io/commons-io/2.0/
 
  Niall
 
  On Thu, Oct 28, 2010 at 9:46 PM, Benson Margulies bimargul...@gmail.com
 wrote:
 
  I can't find common-io 2.0 on Maven. Has it been released?
 
  -
  To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
  For additional commands, e-mail: user-h...@commons.apache.org
 
 
 

 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org




Re: [io] is 2.0 on Maven?

2010-10-29 Thread Niall Pemberton
On Fri, Oct 29, 2010 at 2:13 PM, James Carman
ja...@carmanconsulting.com wrote:
 On Fri, Oct 29, 2010 at 9:07 AM, Niall Pemberton
 niall.pember...@gmail.com wrote:

 I believe it does, but for example if a put a redirection pom in for
 commons-io:commons-io:1.4 to org.apache.commons:commons-io:1.4 the
 problem is that people will already have the old 1.4 pom in their
 local repo and unless they remove the old artifact, the new
 redirection pom will not be downloaded.


 DOH!  Well, that stinks.  I guess we do need to have a discussion on
 how we plan to play nice with respect to all of this
 version/artifact/group management.  I think the plan of keeping the
 artifactId and the package names in sync is a good idea.  But, we need
 to be careful about this whole new groupId thing.  Should we fire up
 a discussion thread on d...@?

We could, but I would suggest a slightly different approach. This has
been discussed in the past and from memory there is more than one
approach that could be taken. The problem with starting a discussion
is that the different points people make about how and the pros and
cons get fragmented among a large thread. I think the best thing would
be to start a Wiki page - that way we could collect all the options
and pros/cons in one place. Once we've done that then its likely to
make any discussion much easier and less contentious. I'm very busy
for the next week, so I'm happy to take part in that - but not just at
the moment.

WDYT?

Niall

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [lang]

2010-10-27 Thread Niall Pemberton
On Wed, Oct 27, 2010 at 2:32 PM, Dirk Starke dirk.sta...@protagen.de wrote:
 Hello,

 I just recognized the following example in class StringUtils:

 StringUtils.indexOfAnyBut(zzabyycdxx, '')  = 0

 I don't understand this example, because [] is used for an empty array
 in the documentation of this method. Could this be corrected or
 explained?

Looks like an error, should be:

StringUtils.indexOfAnyBut(zzabyycdxx, )   = -1

http://commons.apache.org/lang/xref/org/apache/commons/lang3/StringUtils.html#1596

Please file a bug report:

http://commons.apache.org/lang/issue-tracking.html

Thanks

Niall


 Cheers,

 Dirk





-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [validator] Possible to configure multiple error messages for a single validator?

2010-10-05 Thread Niall Pemberton
On Wed, Sep 29, 2010 at 7:09 PM, Christopher Schultz
ch...@christopherschultz.net wrote:
 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 All,

 I've been happily using commons-validator 1.3.1 with Struts 1.3 for some
 years, now, and I've recently developed my own custom validator that
 checks for XHTML syntactic validity. Technically, it checks for XHTML
 validity only when the input looks like this: html/html:
 everything else validates successfully with no actual XHTML syntax check.

 Recently, it became clear that users were sometimes forgetting the
 /html at the end of the input. This caused two problems: first, the
 input wasn't being validated as XHTML, and second, when the data was
 then displayed in a web page, it was escaped instead of being rendered
 as actual HTML.

 My first instinct was to add a mask validator that checked for an
 appropriate pattern (that is, html up front with no trailing
 /html). I implemented that and it works quite well. Then, it
 occurred to me that I might want some other pattern for some reason for
 those fields, and that the correct place for that check ought to be in
 the XHTML validator itself.

 So I started moving the check described above into my custom validator.
 Everything was fine until I had to render the error message. Since I'm
 doing essentially two checks (one for html and matching /html, and a
 second for actually checking the XHTML syntax), I need two distinct
 error messages. The configuration for a validator only allows one single
 msg attribute as shown in my configuration below:

      validator name=possibleXhtml
            classname=PossibleXhtmlValidator
               method=validatePossibleXhtml
         methodParams=java.lang.Object,
                       org.apache.commons.validator.ValidatorAction,
                       org.apache.commons.validator.Field,
                       org.apache.struts.action.ActionMessages,
                       org.apache.commons.validator.Validator,
                       javax.servlet.http.HttpServletRequest
              depends=
                  msg=errors.xhtml /

 I could simply hard-code the error message key into the validator, but
 that seems less maintainable than I'd like it to be. Is it possible to
 provide more than one error message key to a validator like this?

 Other options for me include creating a custom validator that does
 nothing but check for the html.../html that won't interfere with,
 say, the mask validator.

 It still seems to me that my goal ought to be a single validator that is
 basically self-contained, rather than having two validators that
 essentially /must/ be used together.

 Does anyone have any suggestions?

Its been a long time since I worked with Stuts  Validator, but take a
look at the *standard* validators defined in struts:

http://svn.apache.org/viewvc/struts/struts1/trunk/core/src/main/java/org/apache/struts/validator/FieldChecks.java?view=markup

Its the validation implementation that actually adds the messages to
the Struts ActionMessages object - usually by calling

   Resources.getActionMessage(validator, request, va, field))

http://svn.apache.org/viewvc/struts/struts1/trunk/core/src/main/java/org/apache/struts/validator/Resources.java?view=markup

So you need to create your own custom getActionMessage() impl - you
could use the msg returned from the field or validator and use that
as a prefix and append a different suffix for each error.

Alternatively you could define two separate validators - one for each condition.

Niall


 Thanks,
 - -chris
 -BEGIN PGP SIGNATURE-
 Version: GnuPG v1.4.10 (MingW32)
 Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

 iEYEARECAAYFAkyjgOEACgkQ9CaO5/Lv0PBkWwCgjCeACyxBWyv7C4017lfBeMB0
 W6AAnioNsVh8uTgjWCPMIHuKIi6AUTLU
 =7DAj
 -END PGP SIGNATURE-

 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [vfs] How to implement (add) Samba Provider?

2010-09-22 Thread Niall Pemberton
On Wed, Sep 22, 2010 at 10:28 PM, Pavel Bortnovskiy
pbortnovs...@jefferies.com wrote:
 Hi:

 VFS doesn't seem to support smb:// protocol out-of-the-box:  Due to
 some technical reasons we had to move the webdav and jcifs (smb)
 filesystem to the sandbox. So if you need one of these filesystems you
 have to build VFS manuall. I was unable to locate any relevant
 development in the sandbox or locate FileProvider in jCIFS.

 Can anyone please either point me to where such implementation exists, is
 described or show me an example of how such provider may be added?

I thought the vfs sandbox had been included in the source release of
Commons VFS 1.0 - but it seems that it wasn't.

You could check out the 1.0 source from subversion and build the
sandbox module yourself:

http://svn.apache.org/viewvc/commons/proper/vfs/tags/vfs-1.0/

Niall


 Thank you,

 Pavel.

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [beanutils] beanutils library cannot invoke the correct accessor

2010-06-10 Thread Niall Pemberton
On Sun, Jun 6, 2010 at 3:02 AM, Dimitris Tsitses 4.biz@gmail.com wrote:
 Hi all, I'm trying to do something really simple but I can't seem to figure 
 it out, I hope someone can help.

 I have a simple bean:


 public class MyBean {
        private ClassTypeA myProperty;

        public void setMyProperty(ClassTypeA anObj) {
                this.myProperty = anObj;
        }
        public void setMyProperty(ClassTypeB anObj) {
                this.myProperty = Converter.convertBtoA(anObj);
        }

 }

The way to do this in BeanUtils is to get rid of your overloaded
setter for ClassTypeB and register a converter with Beanutils.
Something like...

ClassTypeAConverter converter = new ClassTypeAConverter();
ConvertUtils.register(converter,  ClassTypeA.class);

That way when you use BeanUtils.setProperty() it will call the
converter to convert the ClassTypeB to ClassTypeA.

Niall

 If I invoke the setter by passing an instance of ClassTypeA, it works without 
 a problem:
 BeanUtils.setProperty(myBeanInst, myProperty, instanceOfClassTypeA);


 However if I invoke the setter by passing an instance of ClassTypeB, I get an 
 exception and the setter is never actually called:
 BeanUtils.setProperty(myBeanInst, myProperty, instanceOfClassTypeB);
 java.lang.IllegalArgumentException: Cannot invoke.. la la la - argument type 
 mismatch -

 I can't believe it is not possible to do that, I'm sure I'm just missing 
 something. Any help will be greatly appreciated.

 Many thanks
 Dimitris

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [beanutils] beanutils library cannot invoke the correct accessor

2010-06-10 Thread Niall Pemberton
On Sun, Jun 6, 2010 at 5:55 PM, Dimitris Tsitses 4.biz@gmail.com wrote:
 myProperty is of one type only. The overloaded setters are there only for 
 convenience, i.e., to convert to the type of myProperty before setting it. I 
 don't think the JavaBeans spec disallows that, if it did, that would mean 
 that the JavaBeans spec undermines Java's spec! (i.e., do you like method 
 overloading? Well, you can't use it here!). That would of course severally 
 restrict JavaBeans usefulness.

Well you're wrong about this - if you go an read section 8.3 Design
Patterns for Properties of the Java Bean Specification you will see
it specified a *pair (i.e. getter  setter) of accessor methods for
properties.

http://java.sun.com/javase/technologies/desktop/javabeans/docs/spec.html

Niall

 On 2010-06-06, at 5:50 AM, James Carman wrote:

 That violates the JavaBeans specification.  myProperty is supposed
 to be of one type only.

 On Sat, Jun 5, 2010 at 10:02 PM, Dimitris Tsitses 4.biz@gmail.com 
 wrote:
 Hi all, I'm trying to do something really simple but I can't seem to figure 
 it out, I hope someone can help.

 I have a simple bean:


 public class MyBean {
        private ClassTypeA myProperty;

        public void setMyProperty(ClassTypeA anObj) {
                this.myProperty = anObj;
        }
        public void setMyProperty(ClassTypeB anObj) {
                this.myProperty = Converter.convertBtoA(anObj);
        }

 }

 If I invoke the setter by passing an instance of ClassTypeA, it works 
 without a problem:
 BeanUtils.setProperty(myBeanInst, myProperty, instanceOfClassTypeA);


 However if I invoke the setter by passing an instance of ClassTypeB, I get 
 an exception and the setter is never actually called:
 BeanUtils.setProperty(myBeanInst, myProperty, instanceOfClassTypeB);
 java.lang.IllegalArgumentException: Cannot invoke.. la la la - argument 
 type mismatch -

 I can't believe it is not possible to do that, I'm sure I'm just missing 
 something. Any help will be greatly appreciated.

 Many thanks
 Dimitris

 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [beanutils] beanutils library cannot invoke the correct accessor

2010-06-10 Thread Niall Pemberton
On Mon, Jun 7, 2010 at 5:18 PM, Dimitris Tsitses 4.biz@gmail.com wrote:
 Hi James, thanks for keeping up with my questions.

 So, you mean end up with something like this: ?

 public class MyBean {
       private ClassTypeA myProperty;
       private ClassTypeB myPropertyAsB;
       private ClassTypeC myPropertyAsC;
       private ClassTypeD myPropertyAsD;

       public void setMyProperty(ClassTypeA anObj) {
               this.myProperty = anObj;
       }
       public void setMyPropertyAsB(ClassTypeB anObj) {
               this.myProperty = Converter.convertBtoA(anObj);
       }
        .
        .
        .
 }

 Isn't this hacky as hell, just to compensate for beanutils' lack of basic 
 functionality (i.e., method overloading)? That looks really messy in my 
 opinion, imagine doing that for a number of properties in a few beans. I 
 honestly don't understand why this functionality is missing from beanutils. 
 Anyhow, even if I wanted to do that, I could not in my use case. It's a very 
 dynamic environment where property names are computed automatically based on 
 mappings or field names in a DB. So I couldn't have multiple 'technical' 
 property names for the same 'logical' property without butchering an 
 otherwise very elegant design. I'd rather enhance the beanutils library 
 instead. So the question still stands, how would I go about it?

Hacky as hell is you overloading the accessor methods and will cause
you problems when using your java beans with any technology that
relies on the JavaBean specification - not just BeanUtils. I would
really recommend you avoid doing this.

Niall


 Henri, thanks a lot for the tip about JEXL2, I will look into it and see if 
 it's less work to replace beanutils with that library, instead of enhancing 
 the beanutils library.



 On 2010-06-07, at 5:49 AM, James Carman wrote:

 Why not have another calculated property (myPropertyAsB) that can
 do the translation from ClassTypeB to/from ClassTypeA and store it
 into myProperty?  That way, you don't have to modify the library at
 all?

 On Mon, Jun 7, 2010 at 12:04 AM, Dimitris Tsitses 4.biz@gmail.com 
 wrote:
 Ok. I need some help to hack the library, where do I start. I want to make 
 it so that it checks the available setters against the objectType of the 
 given argument, instead of assuming an argument of a specific type. Example:

 BeanUtils.setProperty(myBeanInst, myProperty, instanceOfClassTypeX);

 Algo: is there a setMyProperty in myBeanInst, accepting an argument of type 
 ClassTypeX?
 YES: call it
 NO: throw exception

 Would appreciate it if someone could point me to the right direction for 
 achieving the above.

 Thanks
 Dimitris


 On 2010-06-06, at 8:24 PM, James Carman wrote:

 The property consists of the getter/setter, not some field.  So, the
 pair of matching setter/getter are what makes up the property.  The
 overloaded method isn't a setter for the property.

 On Sun, Jun 6, 2010 at 12:55 PM, Dimitris Tsitses 4.biz@gmail.com 
 wrote:
 myProperty is of one type only. The overloaded setters are there only for 
 convenience, i.e., to convert to the type of myProperty before setting 
 it. I don't think the JavaBeans spec disallows that, if it did, that 
 would mean that the JavaBeans spec undermines Java's spec! (i.e., do you 
 like method overloading? Well, you can't use it here!). That would of 
 course severally restrict JavaBeans usefulness.


 On 2010-06-06, at 5:50 AM, James Carman wrote:

 That violates the JavaBeans specification.  myProperty is supposed
 to be of one type only.

 On Sat, Jun 5, 2010 at 10:02 PM, Dimitris Tsitses 4.biz@gmail.com 
 wrote:
 Hi all, I'm trying to do something really simple but I can't seem to 
 figure it out, I hope someone can help.

 I have a simple bean:


 public class MyBean {
        private ClassTypeA myProperty;

        public void setMyProperty(ClassTypeA anObj) {
                this.myProperty = anObj;
        }
        public void setMyProperty(ClassTypeB anObj) {
                this.myProperty = Converter.convertBtoA(anObj);
        }

 }

 If I invoke the setter by passing an instance of ClassTypeA, it works 
 without a problem:
 BeanUtils.setProperty(myBeanInst, myProperty, instanceOfClassTypeA);


 However if I invoke the setter by passing an instance of ClassTypeB, I 
 get an exception and the setter is never actually called:
 BeanUtils.setProperty(myBeanInst, myProperty, instanceOfClassTypeB);
 java.lang.IllegalArgumentException: Cannot invoke.. la la la - argument 
 type mismatch -

 I can't believe it is not possible to do that, I'm sure I'm just 
 missing something. Any help will be greatly appreciated.

 Many thanks
 Dimitris

 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



 -
 To unsubscribe, e-mail: 

Re: how to implement login using httpclient?

2010-03-31 Thread Niall Pemberton
On Wed, Mar 31, 2010 at 6:37 PM, maikeru8 msantos.my...@gmail.com wrote:

 I'm still a beginner with regards to Apache Commons, and I wish to implement
 the login for a plugin in Eclipse. The user does not log in via the browser
 but rather Eclipse instead. And I found out about httpclient and I was
 wondering if I could use it to implement the client-side, and then I decided
 to use Java Servlets to implement the server-side.

 Any suggestions on how to use it? Just giving simple examples is good enough
 for me :)

 Thanks for those who will reply. :)

HttpClient left Commons and became a separate project - their mailing
list is here:

http://hc.apache.org/mail.html

Niall

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: Commons-transaction abandoned?

2010-03-07 Thread Niall Pemberton
On Fri, Mar 5, 2010 at 10:01 AM, Oliver Zeigermann
oliver.zeigerm...@gmail.com wrote:
 Folks!

 What Henri says is completely right.

 The project has been abandoned by me as I lost faith in one of its
 goal - ACID properties (especially atomicity) on any file system. From
 my (and others) point of view it can not be achieved by *any*
 implementation. So if you are asking whether there is another
 implementation that is more suitable, my answer is there can't be
 any.

Apologies I'm not familiar with transaction - but does this apply to
the released versions (1.0 to 1.2) - are they flawed or is this
something that only applies to the unreleased 2.0 code base?

Niall

 Certain parts of the 2.0 code are quite reasonable, though, especially
 the locking and deadlock detection part. That's why I have not been
 determined what to do with the project. Certainly 2.0 is better than
 1.x by any means, but I still think it should not be released as its
 promises can not be kept.


 Any thoughts?

 - Oliver

 2010/3/5 Henri Yandell flame...@gmail.com:
 The current version is 1.2 (released in 2007).

 1.3-SNAPSHOT is then the subsequent version in development, but it
 looks as though it was quickly renamed to 2.0.

 2.0 currently has 6 of 9 issues resolved, the most recent being
 reported and applied in Sept 2009, and 2 of the open issues were
 opened a month ago.

 So I wouldn't call it dead - there just hasn't been much to do. Your
 email does raise the question of whether 2.0 should be released or
 not. I've cc'd Oliver who has been doing most of the work.

 Hen

 On Tue, Feb 9, 2010 at 10:07 PM, John Ericksen johncar...@gmail.com wrote:
 Hello,

 I came across the file transaction capabilities in commons-transaction today
 which was exactly what I was looking for.  To my disapointment, however, it
 looks like there hasn't been an update to the project for over 2 years.  The
 home page says the current version is a SNAPSHOT and from my search of the
 mailing list, it looks like 2.0 is upcoming (in 2007?).

 My question is, is the commons-transaction project abandoned, is there a
 better library out there for transactional file system operations?

 Thanks for your reply.

 John



 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [validator] Trouble using global constants in variable values

2010-02-10 Thread Niall Pemberton
On Wed, Feb 10, 2010 at 11:46 PM, Christopher Schultz
ch...@christopherschultz.net wrote:
 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 All,

 On 2/10/2010 6:27 PM, Christopher Schultz wrote:
 constant-value^.*(([0-9]+.*\p{L}+)|(\p{L}+.*[0-9]+)).*$/constant-value
 Okay, something must be wrong with my regular expression, or now I'm
 expressing it in the XML, because when I set it to

  constant-value^[a]+$/constant-value

 ...it will allow me to enter a series of a's and validator will succeed.

You could try testing you're expression directly using
GenericValidator.matchRegexp() until you're happy it works.

http://tinyurl.com/yhe66nm

If it seems correct, but still doesn't seem to work in your Struts app
then perhaps you could write a Struts plugin to retrieve the validator
resources and display the values for the forms/fields/arguments:

http://svn.apache.org/repos/asf/struts/struts1/trunk/core/src/main/java/org/apache/struts/validator/ValidatorPlugIn.java

 If the use of the constant documented anywhere? I couldn't find
 anything on the website, in the wiki, etc. I was only lucky that I
 thought of looking in the DTD to see that it was possible, and that the
 Constant class from way back in version 1.0.1 has been indexed by
 Google to see what the syntax was supposed to be.

 I'd be happy to contribute some documentation if I know what form is best.

Struts has documentation on using validator:

http://struts.apache.org/1.3.10/faqs/validator.html#ConstantsVariables

Niall

 Thanks,
 - -chris

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: Problem of 404 with apache tomcat mod_jk

2010-01-09 Thread Niall Pemberton
You have the wrong mailing list - try the Tomcat User list

http://tomcat.apache.org/lists.html

Niall

On Thu, Jan 7, 2010 at 5:11 PM,  vishal.mes...@techprocess.co.in wrote:
 Hi all,



 We are getting http 404 error sometimes.NOT all times..



 Can any one help us how to proceed in order to debug this issue..and what
 could be possible problems?



 Thanx in advance for ur help.



 Please find attached log of webserver ..





 2009-12-30 10:30:45 GMT Starting to Push files to xxx PROD

 2009-12-30 10:30:45 GMT  Invoke : index=1 depth=1

 2009-12-30 10:30:45 GMT  Invoke : index=1 depth=1

 2009-12-30 10:30:45 GMT  DataCheck: data mismatch

 2009-12-30 10:30:45 GMT  Invoke : index=1 depth=1

 2009-12-30 10:30:45 GMT  Opening Socket
 https://xxx..xxx/FileDownload/pushFile  proxy=xxx.xxx.xxx.xxx:80

 2009-12-30 10:30:45 GMT  -- CONNECT xxx..xxx:443 HTTP/1.0

 2009-12-30 10:30:45 GMT  -- User-Agent: Mozilla/4.0 [en] (WinNT; I)

 2009-12-30 10:30:45 GMT  -- Accept: image/gif, */*

 2009-12-30 10:30:45 GMT  -- Host: xxx..xxx

 2009-12-30 10:30:45 GMT  -- Authorization: Basic Y2l0aWJhbms6Y2l0aWJhbms=

 2009-12-30 10:30:45 GMT  -- Content-type: multipart/form-data

 2009-12-30 10:30:45 GMT  -- Filename: PRED_20091230160003.xml

 2009-12-30 10:30:45 GMT  HTTP/1.0 200

 2009-12-30 10:30:46 GMT  -- POST /FileDownload/pushFile HTTP/1.0

 2009-12-30 10:30:46 GMT  -- User-Agent: Mozilla/4.0 [en] (WinNT; I)

 2009-12-30 10:30:46 GMT  -- Accept: image/gif, */*

 2009-12-30 10:30:46 GMT  -- Host: xxx..xxx

 2009-12-30 10:30:46 GMT  -- Authorization: Basic Y2l0aWJhbms6Y2l0aWJhbms=

 2009-12-30 10:30:46 GMT  -- Content-type: multipart/form-data

 2009-12-30 10:30:46 GMT  -- Filename: PRED_20091230160003.xml

 2009-12-30 10:30:46 GMT  -- Content-Length: 6526

 2009-12-30 10:30:47 GMT  HTTP/1.1 404

 2009-12-30 10:30:47 GMT  -- Date: Wed, 30 Dec 2009 10:30:46 GMT

 2009-12-30 10:30:47 GMT  -- Server: Apache/2.2.4 (Win32) mod_ssl/2.2.4
 OpenSSL/0.9.8d mod_jk/1.2.25

 2009-12-30 10:30:47 GMT  -- ETag: W/1081-1212647975312

 2009-12-30 10:30:47 GMT  -- Last-Modified: Thu, 05 Jun 2008 06:39:35 GMT

 2009-12-30 10:30:47 GMT  -- Content-Length: 1081

 2009-12-30 10:30:47 GMT  -- Connection: close

 2009-12-30 10:30:47 GMT  -- Content-Type: text/html

 2009-12-30 10:30:47 GMT  Invoke : index=1 depth=1

 2009-12-30 10:30:47 GMT  Invoke : index=1 depth=1

 2009-12-30 10:30:47 GMT HTTP to xxx PROD /FileDownload/pushFile with
 Status 404





 Rgd

 vishal

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: DBCP - Unable to successfully call Connection.createArrayOf() method

2009-12-16 Thread Niall Pemberton
The createArrayOf() method was added in JDBC 4 / JDK 1.6:

http://tinyurl.com/yhwwejv

The current release of DBCP doesn't currently support JDBC 4 which is
why you're seeing this error. Commons is currently going through the
process of releasing DBCP 1.4 which will support JDBC 4 - hopefully
this will be available in the next couple of weeks.

Niall


On Wed, Dec 16, 2009 at 7:24 AM, Allan Kamau kamaual...@gmail.com wrote:
 I am trying create an array of text to pass to a postgreSQL function
 and I am getting the following error
 java.lang.AbstractMethodError:
 org.apache.commons.dbcp.PoolingDataSource$PoolGuardConnectionWrapper.createArrayOf(Ljava/lang/String;[Ljava/lang/Object;)Ljava/sql/Array;

 I have tried googling for a possible solution without much success the
 closed I got was the discussion in this thread
 http://archives.postgresql.org/pgsql-jdbc/2009-04/msg00013.php;

 I am using JDBC driver (postgresql-8.4-701.jdbc4.jar) for postgreSQL
 and commons-dbcp-1.2.2.jar for connection pooling.

 My code like like this.


        public static int persistUserInput(
                Connection conn,String 
 _user_input_id,MapString,VectorString userInputMap
        )throws SQLException
        {
                int _rows_affected=-1;
                String _input_name=null;
                String _input_values[]=new String[0];
                PreparedStatement ps=null;ResultSet rs=null;
                for (Map.EntryString,VectorString y : 
 userInputMap.entrySet())
                {
                        _input_name=y.getKey();
                        VectorString v=y.getValue();
                        _input_values=v.toArray(_input_values);
                        try
                        {

                                String _sql_query=
                                        + SELECT persist_user_input(?,?,?);
                                ;
                                ps=conn.prepareStatement(_sql_query);
                                ps.setString(1,_user_input_id);
                                ps.setString(2,_input_name);
                                
 ps.setArray(3,conn.createArrayOf(text,_input_values));
                                rs=ps.executeQuery();
                                if(rs.next())
                                {
                                        _rows_affected=rs.getInt(1);
                                }
                                rs.close();
                                ps.close();
                        }
                        catch(SQLException e)
                        {
                                throw e;
                        }
                        finally
                        {
                                /*
                                rs.close();
                                ps.close();
                                if(rs!=null!rs.isClosed())
                                {
                                        rs.close();
                                }
                                rs=null;
                                if(ps!=null!ps.isClosed())
                                {
                                        ps.close();
                                }
                                ps=null;
                                */
                        }
                }
                return _rows_affected;
        }

 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org




Re: Setting null on Integer property via BeanUtils.setProperty

2009-12-09 Thread Niall Pemberton
On Wed, Dec 9, 2009 at 11:22 AM, Syed Muhammad Humayun
smhuma...@iblgrp.com wrote:
 Niall,

 Thanx for the help. I did following as a work around:

 PropertyUtils.getWriteMethod(PropertyUtils.getPropertyDescriptor(this,
 propertyName)).invoke(this, new Object[]{null});

Why not just use

   PropertyUtils.setProperty(bean, propertyName, null);

Niall

 Regards,

 ---
 S M Humayun
 Software Architect, IBL Group
 ---
 Cell : 92.321.8707783
 Email (Official) : smhuma...@iblgrp.com
 Email (Personal) : smhuma...@gmail.com
 Google Talk : smhuma...@gmail.com
 MSN : smhumayun2...@hotmail.com
 Yahoo : humayun_repo...@yahoo.com
 Skype : smhumayun
 AIM : syedmohdhumayun
 Blog : http://smhumayun.blogspot.com
 LinkedIn : http://www.linkedin.com/in/smhumayun
 Facebook : http://www.facebook.com/smhumayun
 Twitter : http://twitter.com/smhumayun
 Flickr : http://www.flickr.com/photos/smhumayun
 YouTube : http://www.youtube.com/user/smhumayun
 ---
 -Original Message-
 From: Niall Pemberton [mailto:niall.pember...@gmail.com]
 Sent: Wednesday, December 09, 2009 4:18 PM
 To: Commons Users List
 Subject: Re: Setting null on Integer property via BeanUtils.setProperty

 On Wed, Dec 9, 2009 at 10:06 AM, Syed Muhammad Humayun
 smhuma...@iblgrp.com wrote:
 Hi,

 How can I set a 'null' on Integer property (or any other wrappers like
 Double, Long, Character etc) via BeanUtils.setProperty? If its not
 possible this way than is there any other way using apache commons ?

 If you don't want conversion then you can use
 org.apache.commons.beanutils.PropertyUtils.setProperty() method - but the
 value object has to be the correct type (or null).

 For PropertyUtils see: http://tinyurl.com/yf9f6wk

 BeanUtils adds conversion to PropertyUtils  - it tries to convert the value
 you specified to the correct type of the the bean's property.
 These converters have behaviour defined on how to handle null values and
 operate in two modes:
  - throw an exception
  - use a default value

 The default set of converters which are registered with BeanUtils have a
 default value specified - so for example the converter registered for
 Integer types has a default value of zero. This is why you can't set a
 null value at the moment. If you want null values to be set then you need
 to register converter implementations for those types with a default value
 of null. So for example you would do something like...

  ConvertUtils.register(new IntegerConverter(null), Integer.class);
  ConvertUtils.register(new DoubleConverter(null), Double.class);

 (Note: the null value in the constructors is the default value)

 For ConvertUtils see: http://tinyurl.com/ydhq85s For converters see:
 http://tinyurl.com/yl2pl2q

 Niall

 Regards,

 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org





 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: File upload: not identified content type.

2009-11-04 Thread Niall Pemberton
AIUI it gets it from the request headers:

http://commons.apache.org/fileupload/xref/org/apache/commons/fileupload/FileUploadBase.html#993

Niall

On Wed, Nov 4, 2009 at 5:26 PM, vijay shanker vijay.s...@gmail.com wrote:
 Hello friends;

 I am using commons file upload library to upload files. I have been noticing
 some time my library does not get file content type correct. For such a file
 it saves *application*/*octet*-*stream. *

 Can any body describe how it does happens?

 If some of you have known for such a situation. Please share the
 information.
 **
 Regards,
 Vijay Shanker Dubey
 Ph: +91-9818311884


-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [BeanUtils] dependencies

2009-10-28 Thread Niall Pemberton
On Wed, Oct 28, 2009 at 10:44 AM, Joonas Pulakka joonas.pula...@iki.fi wrote:
 Hello,

 I'm wondering what external dependencies BeanUtils actually has. On the main
 page http://commons.apache.org/beanutils/ it's mentioned
 that commons-beanutils.jar has an optional dependency on Collections. What
 does optional mean? Here

You need Commons Collections if you use any of the following classes:
BeanMap
BeanPredicate
BeanPropertyValueChangeClosure
BeanPropertyValueEqualsPredicate
BeanToPropertyValueTransformer

 http://commons.apache.org/beanutils/dependencies.html it additionally says
 Logging is a dependency. And then, here is stated that both Collections and
 Logging packages are a _requirement_:
 http://commons.apache.org/beanutils/apidocs/org/apache/commons/beanutils/package-summary.html#overview.dependencies

That page is out of date wrt to Commons Collections - patches welcome

 Still, I've done some (very basic) successful experiments with BeanUtils
 with neither Collections nor Logging on the Classpath. What's the deal?

I'm surprised that you didn't have any issues without commons logging
since some of the core features of beanutils use them.

Niall


 Best Regards,
 Joonas


-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [BeanUtils] dependencies

2009-10-28 Thread Niall Pemberton
On Wed, Oct 28, 2009 at 3:45 PM, Brent Worden brent.wor...@gmail.com wrote:
 On Wed, Oct 28, 2009 at 6:03 AM, Niall Pemberton
 niall.pember...@gmail.comwrote:

 On Wed, Oct 28, 2009 at 10:44 AM, Joonas Pulakka joonas.pula...@iki.fi
 wrote:
  Hello,
 
  I'm wondering what external dependencies BeanUtils actually has. On the
 main
  page http://commons.apache.org/beanutils/ it's mentioned
  that commons-beanutils.jar has an optional dependency on Collections.
 What
  does optional mean? Here

 You need Commons Collections if you use any of the following classes:
    BeanMap
    BeanPredicate
    BeanPropertyValueChangeClosure
    BeanPropertyValueEqualsPredicate
    BeanToPropertyValueTransformer

  http://commons.apache.org/beanutils/dependencies.html it additionally
 says
  Logging is a dependency. And then, here is stated that both Collections
 and
  Logging packages are a _requirement_:
 
 http://commons.apache.org/beanutils/apidocs/org/apache/commons/beanutils/package-summary.html#overview.dependencies

 That page is out of date wrt to Commons Collections - patches welcome


 I took the liberty of checking in changes to the package.html.  Feel free to
 critique.

Hey thanks! Looks good to me.

Niall

 Thanks,

 Brent


-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



[ANNOUNCE] Commons BeanUtils 1.8.1 released

2009-10-21 Thread Niall Pemberton
The Commons team is pleased to announce the release of Commons BeanUtils 
1.8.1.



This release contains a number of bug fixes for the 1.8.0 release - full 
details of which can be found in the release notes:


  http://commons.apache.org/beanutils/v1.8.1/RELEASE-NOTES.txt


For information on Commons BeanUtils please visit the BeanUtils website:

  http://commons.apache.org/beanutils/


BeanUtils can be downloaded from the following page:

  http://commons.apache.org/beanutils/download_beanutils.cgi


Niall
on behalf of the Commons community



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: NPE from DBCP connection pool

2009-10-08 Thread Niall Pemberton
On Thu, Oct 8, 2009 at 8:16 PM, TomStrummer tomstrum...@gmail.com wrote:

 Anyone ever seen this before?  A NPE from PoolingConnection.normalizeSQL:

 java.lang.NullPointerException
         at
 org.apache.commons.dbcp.PoolingConnection.normalizeSQL(PoolingConnection.java:178)
         at
 org.apache.commons.dbcp.PoolingConnection.createKey(PoolingConnection.java:170)
         at
 org.apache.commons.dbcp.PoolingConnection.prepareStatement(PoolingConnection.java:92)
         at
 org.apache.commons.dbcp.DelegatingConnection.prepareStatement(DelegatingConnection.java:248)
         at
 org.apache.commons.dbcp.PoolingDataSource$PoolGuardConnectionWrapper.prepareStatement(PoolingDataSource.java:302)


 I've got a BasicDataSource and I'm trying to run a relatively simple query.
 Not sure where the NPE could be coming from.  The SQL statement in question
 is extremely simple, a single-column SELECT with a single JOIN and a WHERE
 clause.  It works fine in a SQL browser.  The query is Oracle 11g, but I'm
 pretty sure that doesn't matter since it doesn't look like the query is
 getting that far.

The sql statement you're passing in has got to be null since the
normalizeSQL() method only does sql.trim(). Also it would make
investigation issues much easier if you specify the version of DBCP
you are using.

Niall

 Note that other queries still work, just this one in particular.  So it's
 not an issue with connections closing or something like that.  Any ideas?

 Thanks.
 -Tom
 --

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: Does I download other commond jars for using the common configurnation

2009-09-28 Thread Niall Pemberton
On Mon, Sep 28, 2009 at 9:34 AM, maven apache apachemav...@gmail.com wrote:
 I am using the common configurnation, first I found the error message which
 tell me the class org.apache.commons.lang.exception.NestableException can
 not be resovled, so I download the common lang jar, then this error does not
 exist,however another message:java.lang.NoClassDefFoundError:
 org/apache/commons/collections/Predicate
 Then I get a message box  can not find the main class,Program will exit 
 I wonder why, does it mean I should add the common collection jar? if so
 ,how many jars I need to add ?

Yes you need a minimum of logging, lang and collections:

http://commons.apache.org/configuration/dependencies.html

Niall

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: log4j NTEventLogAppender.dll for windows 64 bit

2009-09-02 Thread Niall Pemberton
On Tue, Sep 1, 2009 at 10:27 PM, Trin
Chavalittumrongtri...@microsoft.com wrote:
 Hi All,

 The NTEVentLogAPpender.dll that comes with log4j seems to be working with 
 Windows 32-bit only. Has anyone had any solutions for this problem in Windows 
 64-bit?

Wrong list, try http://logging.apache.org/mail-lists.html

Niall

 Thanks,
 Trin


-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [VFS] Minimum Java version

2009-08-19 Thread Niall Pemberton
On Wed, Aug 19, 2009 at 3:34 PM, Ralph Goersralph.go...@dslextreme.com wrote:
 The packages haven't been changed so far. But this would definitely have to
 be considered whether we would want to take on the package renaming right
 now.

With IO there were only a couple of JDK 1.5 changes  that would have
broken compatibility - so we didn't make those changes and therefore
haven't had to do a package re-name. If VFS decides to moved to JDK
1.5 I would suggest doing compatible changes first and then creating a
list/patch of incompatible changes for review - then make the decision
based on how desirable/major/minor those changes are.

Niall

 The minimum JDK for 1.0 was 1.3, although it isn't clear that that was
 correct. The minimum JDK for 2.0 has already been changed to 1.4 since some
 of the code actually required that version to run.

 Ralph

 On Aug 19, 2009, at 7:24 AM, James Carman wrote:If

 Are they going to change the package name?

 On Wed, Aug 19, 2009 at 10:18 AM, Ralph Goersralph.go...@dslextreme.com
 wrote:

 Currently the minimum Java version for VFS 2.0 is 1.4.  VFS 2.0 has not
 been
 released and the developers are considering making the minimum version
 JDK
 5. We are interested in getting feedback from the community however
 before
 this change is made.  So please respond with your thoughts on this.

 Ralph

 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



 -
 To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org
 For additional commands, e-mail: dev-h...@commons.apache.org



 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [VFS] Minimum Java version

2009-08-19 Thread Niall Pemberton
On Wed, Aug 19, 2009 at 5:22 PM, Gary
Gregoryggreg...@seagullsoftware.com wrote:
 -Original Message-
 From: Niall Pemberton [mailto:niall.pember...@gmail.com]
 Sent: Wednesday, August 19, 2009 7:40 AM
 To: Commons Users List
 Subject: Re: [VFS] Minimum Java version

 On Wed, Aug 19, 2009 at 3:34 PM, Ralph Goersralph.go...@dslextreme.com
 wrote:
  The packages haven't been changed so far. But this would definitely have
 to
  be considered whether we would want to take on the package renaming
 right
  now.

 With IO there were only a couple of JDK 1.5 changes  that would have
 broken compatibility - so we didn't make those changes and therefore
 haven't had to do a package re-name. If VFS decides to moved to JDK
 1.5 I would suggest doing compatible changes first and then creating a
 list/patch of incompatible changes for review - then make the decision
 based on how desirable/major/minor those changes are.

 That seems to complicate matters IMO. If we care about having v1 and v2 
 co-exist in a Java 5 application, then the v2 packages must to be renamed. So 
 if that is what we want, let us just bite the bullet and rename now.

I don't really get why you say it complicates matters as being
backwards compatible means that you don't need v1  v2 to co-exist.

Niall

 Gary


 Niall

  The minimum JDK for 1.0 was 1.3, although it isn't clear that that was
  correct. The minimum JDK for 2.0 has already been changed to 1.4 since
 some
  of the code actually required that version to run.
 
  Ralph
 
  On Aug 19, 2009, at 7:24 AM, James Carman wrote:If
 
  Are they going to change the package name?
 
  On Wed, Aug 19, 2009 at 10:18 AM, Ralph
 Goersralph.go...@dslextreme.com
  wrote:
 
  Currently the minimum Java version for VFS 2.0 is 1.4.  VFS 2.0 has
 not
  been
  released and the developers are considering making the minimum version
  JDK
  5. We are interested in getting feedback from the community however
  before
  this change is made.  So please respond with your thoughts on this.
 
  Ralph
 
  -
  To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
  For additional commands, e-mail: user-h...@commons.apache.org
 
 
 
  -
  To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org
  For additional commands, e-mail: dev-h...@commons.apache.org
 
 
 
  -
  To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
  For additional commands, e-mail: user-h...@commons.apache.org
 
 

 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org


 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: Commons codec 1.4 on maven repo?

2009-08-18 Thread Niall Pemberton
On Mon, Aug 17, 2009 at 6:43 PM, Gary
Gregoryggreg...@seagullsoftware.com wrote:
 I do not recall seeing an announcement email for the release. Did I miss it?

No I've been on holiday so its the only thing left todo.

Niall


 Gary

 -Original Message-
 From: Marvin Froeder [mailto:velo...@gmail.com]
 Sent: Monday, August 17, 2009 10:18 AM
 To: user@commons.apache.org
 Subject: Commons codec 1.4 on maven repo?

 Hi Folks,
 commons-codec 1.4 is not available at maven central
 http://repo1.maven.org/maven2/commons-codec/commons-codec/

 Only 1.3



 VELO

 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: Release codec 1.4?

2009-07-31 Thread Niall Pemberton
On Fri, Jul 31, 2009 at 9:20 PM, Gary
Gregoryggreg...@seagullsoftware.com wrote:
 Hi Tom:

 I need to look at the patch for [CODEC-59] and then make sure our test 
 coverage is a good as before the patch. Then we can cut another RC and people 
 can look at the bits and vote.

 My intention is to look at [CODEC-59] later today or over the weekend.

I'm going on holiday in just over a week so perhaps better if someone
else does the RM role. If noone else wants to do it, then I could
probably do it if its ready to go in the next day or so - or after I
get back.

Niall

 Gary

 -Original Message-
 From: TomStrummer [mailto:tomstrum...@gmail.com]
 Sent: Friday, July 31, 2009 1:10 PM
 To: user@commons.apache.org
 Subject: RE: Release codec 1.4?


 Not to bug you Gary, but any update on this?

 I'm really looking for CODEC-69 (Streaming Base64).  Are the current
 1.4-SNAPSHOT builds published anywhere?  The project website says the
 current version is 1.4-SNAPSHOT but I only see downloads for 1.3.  The
 http://people.apache.org/repo/m2-snapshot-repository/ doesn't seem to have
 anything from commons-codec.

 Thanks.
 -Tom



 Gary Gregory wrote:
 
  Julius,
 
  I will look at CODEC-75 this week.
 
  Gary
 
  -Original Message-
  From: Julius Davies [mailto:juliusdav...@gmail.com]
  Sent: Monday, July 13, 2009 11:05 AM
  To: Commons Users List
  Subject: Re: Release codec 1.4?
 
  Hi,
 
  I'm mostly happy with the state of the CODEC in the repository.
  Base64 can be properly streamed when using the repository version, and
  I believe it's at least 33% faster than any of these:
 
  1. http://iharder.sourceforge.net/base64/   (2 times faster)
  2. sun.misc.BASE64Decoder   (2 times faster)
  3. openssl enc -base64 -d   (about 33% faster?)
 
  Obviously I wish the patch I submitted for CODEC-75 would be applied
  (I'm privately forking for my own needs).
 
 
  yours,
 
  Julius
 
 
 
  On Sun, Jul 12, 2009 at 4:55 PM, da...@davidkarlsen.com wrote:
   On Sun, 12 Jul 2009, Gary Gregory wrote:
  
   Note that due to the Caverphone class, the requirement for a Codec
 1.4
   release will be changed from Java 1.3.1 to 1.4.2. I think this is
 fine
  and
   reworking Caverphone to be Java 1.3 compliant is not worth the
 effort.
  
   Is that an issue for anyone?
  
   Not for me - and can't really imagine for any else either, actually
 1.4
  was
   EOSL October last year: http://java.sun.com/j2se/1.4.2/download.html
  
   If they haven't moved yet they'll have bigger problems than commons
  codec
   requiring it from v1.4 :)
  
   And - a big thanks!
  
   --
   David J. M. Karlsen - +47 90 68 22 43
   http://www.davidkarlsen.com
   http://mp3.davidkarlsen.com
  
   -
   To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
   For additional commands, e-mail: user-h...@commons.apache.org
  
  
 
 
 
  --
  yours,
 
  Julius Davies
  250-592-2284 (Home)
  250-893-4579 (Mobile)
  http://juliusdavies.ca/logging.html
 
  -
  To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
  For additional commands, e-mail: user-h...@commons.apache.org
 
 
  -
  To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
  For additional commands, e-mail: user-h...@commons.apache.org
 
 
 

 --
 View this message in context: http://www.nabble.com/Release-codec-1.4--
 tp2263p24762389.html
 Sent from the Commons - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org


 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [Sanselan] Writing XMP leads to semi-corrupted IPTC

2009-07-13 Thread Niall Pemberton
On Tue, Jul 14, 2009 at 1:47 AM, Charles Matthew
Chencharlesmc...@gmail.com wrote:
 +dev

 Hi Jonathan,

   Sanselan is in the process of moving into the Commons project - bear with 
 us.

   dev, user: how does Commons handle issue tracking?  Should we open
 an issue for this issue in our old JIRA issue tracker?

Looks to me like the existing Sanselan JIRA issue tracker has just
been moved under commons. So yes nothing changes with creating issues
- you can either point people to the same JIRA url here:

http://issues.apache.org/jira/browse/SANSELAN

or theres a page on the Sanselan site which provides guidance and
useful urls for the Sanselan JIRA instance:

http://commons.apache.org/sanselan/issue-tracking.html

Niall


   Jonathan: once we've sorted out the issue tracking question, please
 open an issue.  It would be very helpful if you could
 attach/contribute an image and source that reproduce the issue.  A
 code snippet that demonstrates how you are using Sanselan is fine.

 Matthew


 On Mon, Jul 13, 2009 at 6:25 PM, Jonathan
 Gilesjonat...@jonathangiles.net wrote:
 Hi there everyone,

 I'm trying to use Sanselan to write XMP data to an image. The problem is
 that in doing so, it appears to corrupt the other IPTC data such that it is
 not visible in all circumstances (i.e. Windows Explorer doesn't display it).
 It's there in the file, just not in the expected location perhaps.

 Is there a way to handle this such that the added XMP doesn't change the
 content of the rest of the file? I tried re-writing the IPTC metadata but to
 no avail. Perhaps I haven't discovered the magic sequence of events that
 need to be followed.

 Any pointers would be much appreciated!
 Cheers,
 Jonathan Giles



 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [Net] Whom to contact

2009-05-16 Thread Niall Pemberton
On Fri, May 15, 2009 at 12:37 PM, Olli Loikkanen
olli.loikka...@gmail.com wrote:
 Hi,

 The webpage http://commons.apache.org/ seems to lack information. I
 could not find contact information of any particular person/webmaster
 who is responsible for updating the webpage. Thefore I sent this email
 to this mailing list. Of course if this is the only way to contact the
 webmaster, that's fine... but it could still be more clearly stated on
 the webpage.

Either here or on the dev list.

 First of all the nightly builds link on the download page of the Net
 component is not working.

There are no nightlies being built  now.

 The page containing the link is:
 http://commons.apache.org/net/download.html

 Not working link leads to the following URL:
 http://jakarta.apache.org/builds/jakarta-commons/nightly/commons-net/

 I could find a nightly snapshot link from the main page
 http://commons.apache.org/ . The latest nightly snapshot of the Net
 component seems to be from 2007.
 I assume that nightly snapshots of the Net component are not provided
 anymore since the latest release in 2008 is more fresh than the last
 nightly snapshot I could find? Please correct me if I'm wrong and
 there is another location where to find the nightly snapshots.

 My last concern this time is the MDTM command. It throws an exception
 and it seems that there _commands array in the FTPCommand class is
 lacking the MDTM command, but since I have only the latest release
 build at hand I cannot verify if this has been already corrected or if
 a bug report should be filed?

You can look at the current source,

http://commons.apache.org/net/source-repository.html

...and for Net 2.x thats here
http://svn.apache.org/repos/asf/commons/proper/net/branches/NET_2_0/src/main/java/org/apache/commons/net/ftp/FTPCommand.java

Looks like MDTM has since been added:

http://svn.apache.org/viewvc?view=revrevision=740956
http://issues.apache.org/jira/browse/NET-248

Niall

 Br,
 Olli Loikkanen

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: org.apache.commons.digester.rss.* ?

2009-04-06 Thread Niall Pemberton
On Mon, Apr 6, 2009 at 5:59 PM, Christian Grobmeier grobme...@gmail.com wrote:
 On Mon, Apr 6, 2009 at 6:54 PM, k2 karlk...@spiritone.com wrote:
 So to put this simply, is there an ftp location for the example files from
 where I can download the source tree for rss?

 No you have to go through SVN best.

They are in the source distro that you can download in the usual place:

http://commons.apache.org/downloads/download_digester.cgi

Niall

 Try this:
 svn checkout http://svn.apache.org/repos/asf/commons/proper/digester/trunk
 commons-digester

 If you use Windows, try Tortoise for comfortable svn checkout
 tortoisesvn.tigris.org/

 Cheers



 k2 wrote:

 Rahul Akolkar wrote:

 Thats part of the examples, not the library. You can get it here (and
 build it yourself):


  http://svn.apache.org/repos/asf/commons/proper/digester/trunk/src/examples/rss/



 So is the best way to get to this code through subversion? Doing this file
 by file via HTTP is a bit of a hassle



 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



 -
 To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
 For additional commands, e-mail: user-h...@commons.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: bean utils : automatic type conversion newbie question

2009-03-03 Thread Niall Pemberton
On Tue, Mar 3, 2009 at 2:24 PM, Paul Hussein paul.huss...@hapnin.net wrote:
 Hi,

 I am trying to use Bean Utils to fill my bean. I am expecting automatic
 conversion from String to BigDecimal or Float and various other base types.
 However for me this is not working.


 When I call

 PropertyUtils.setProperty(bean, VALUE, 125.0)

PropertyUtils doesnt do conversion - it just calls the setter with the
supplied value - you need to use BeanUtils to get value conversion,
try

BeanUtils.setProperty(bean, VALUE, 125.0)

Niall

 on a method

    public void setVALUE(Float VALUE) {

 I get the error 'argument type mismatch - had objects of type
 java.lang.String but expected signature java.lang.Float'

 Am I missing somethimg ? DO I have to explicitly state which converters to
 use automatically ???

 Thanks

 Paul.


 0    [main] DEBUG
 org.apache.commons.beanutils.converters.BooleanConverter.setDefaultValue  -
 Setting default value: false
 6    [main] DEBUG
 org.apache.commons.beanutils.converters.BooleanConverter.convert  -
 Converting 'Boolean' value 'false' to type 'Boolean'
 8    [main] DEBUG
 org.apache.commons.beanutils.converters.BooleanConverter.convert  -     No
 conversion required, value is already a Boolean
 16   [main] DEBUG
 org.apache.commons.beanutils.converters.ByteConverter.setDefaultValue  -
 Setting default value: 0
 19   [main] DEBUG
 org.apache.commons.beanutils.converters.ByteConverter.convert  - Converting
 'Integer' value '0' to type 'Byte'
 27   [main] DEBUG
 org.apache.commons.beanutils.converters.ByteConverter.convert  -
 Converted to Byte value '0'
 30   [main] DEBUG
 org.apache.commons.beanutils.converters.CharacterConverter.setDefaultValue
 - Setting default value:
 32   [main] DEBUG
 org.apache.commons.beanutils.converters.CharacterConverter.convert  -
 Converting 'Character' value ' ' to type 'Character'
 33   [main] DEBUG
 org.apache.commons.beanutils.converters.CharacterConverter.convert  -     No
 conversion required, value is already a Character
 36   [main] DEBUG
 org.apache.commons.beanutils.converters.DoubleConverter.setDefaultValue  -
 Setting default value: 0
 37   [main] DEBUG
 org.apache.commons.beanutils.converters.DoubleConverter.convert  -
 Converting 'Integer' value '0' to type 'Double'
 38   [main] DEBUG
 org.apache.commons.beanutils.converters.DoubleConverter.convert  -
 Converted to Double value '0.0'
 40   [main] DEBUG
 org.apache.commons.beanutils.converters.FloatConverter.setDefaultValue  -
 Setting default value: 0
 41   [main] DEBUG
 org.apache.commons.beanutils.converters.FloatConverter.convert  - Converting
 'Integer' value '0' to type 'Float'
 42   [main] DEBUG
 org.apache.commons.beanutils.converters.FloatConverter.convert  -
 Converted to Float value '0.0'
 44   [main] DEBUG
 org.apache.commons.beanutils.converters.IntegerConverter.setDefaultValue  -
 Setting default value: 0
 46   [main] DEBUG
 org.apache.commons.beanutils.converters.IntegerConverter.convert  -
 Converting 'Integer' value '0' to type 'Integer'
 47   [main] DEBUG
 org.apache.commons.beanutils.converters.IntegerConverter.convert  -     No
 conversion required, value is already a Integer
 48   [main] DEBUG
 org.apache.commons.beanutils.converters.LongConverter.setDefaultValue  -
 Setting default value: 0
 49   [main] DEBUG
 org.apache.commons.beanutils.converters.LongConverter.convert  - Converting
 'Integer' value '0' to type 'Long'
 50   [main] DEBUG
 org.apache.commons.beanutils.converters.LongConverter.convert  -
 Converted to Long value '0'
 52   [main] DEBUG
 org.apache.commons.beanutils.converters.ShortConverter.setDefaultValue  -
 Setting default value: 0
 54   [main] DEBUG
 org.apache.commons.beanutils.converters.ShortConverter.convert  - Converting
 'Integer' value '0' to type 'Short'
 55   [main] DEBUG
 org.apache.commons.beanutils.converters.ShortConverter.convert  -
 Converted to Short value '0'
 58   [main] DEBUG
 org.apache.commons.beanutils.converters.BigDecimalConverter.setDefaultValue
 - Setting default value: 0.0
 59   [main] DEBUG
 org.apache.commons.beanutils.converters.BigDecimalConverter.convert  -
 Converting 'BigDecimal' value '0.0' to type 'BigDecimal'
 60   [main] DEBUG
 org.apache.commons.beanutils.converters.BigDecimalConverter.convert  -
 No conversion required, value is already a BigDecimal
 63   [main] DEBUG
 org.apache.commons.beanutils.converters.BigIntegerConverter.setDefaultValue
 - Setting default value: 0
 64   [main] DEBUG
 org.apache.commons.beanutils.converters.BigIntegerConverter.convert  -
 Converting 'BigInteger' value '0' to type 'BigInteger'
 65   [main] DEBUG
 org.apache.commons.beanutils.converters.BigIntegerConverter.convert  -
 No conversion required, value is already a BigInteger
 66   [main] DEBUG
 org.apache.commons.beanutils.converters.BooleanConverter.setDefaultValue  -
 Setting default value: false
 67   [main] DEBUG
 org.apache.commons.beanutils.converters.BooleanConverter.convert  -
 Converting 'Boolean' value 'false' to type 

Re: [beanutils] converting HTTP params into an arbitrary object model

2009-02-25 Thread Niall Pemberton
On Tue, Feb 24, 2009 at 3:09 PM, Matt Benson gudnabr...@yahoo.com wrote:

 --- On Tue, 2/24/09, Adam Hardy ahardy.str...@cyberspaceroad.com wrote:

 From: Adam Hardy ahardy.str...@cyberspaceroad.com
 Subject: Re: [beanutils] converting HTTP params into an arbitrary object 
 model
 To: Commons Users List user@commons.apache.org
 Date: Tuesday, February 24, 2009, 3:19 AM
 Matt Benson on 23/02/09 16:23,
 wrote:
 --- On Sat, 2/21/09, Adam Hardy wrote:
I have spent a day researching and
 prototyping with various open-source
  options available which facilitate converting an
 HTTP request's parameters into an object model of javabeans
 in a JPA persistence framework.
 
 
  You may want to check out Morph @ http://morph.sourceforge.net .  OOTB, it 
  can
 reflect ServletRequest parameters as bean properties and
 do a straight copy, as long as the servlet API is found on
 the classpath.

 I had a look at morph (following the link from the
 beanutils wiki) but their
 website didn't really enlighten me and what I did find
 didn't look very helpful,
 so I made a management decision not to pursue it.

 The problem is that there are that many little details to
 check for, e.g. can it handle sets, can it deduce the
 javabean items on generics, can it handle indexed lists of
 .0, .1, .2 notation etc


 Morph is not generics-enabled; it can handle most of your basic non-generic 
 constructs (e.g. Sets) right out of the box and just about anything else you 
 can throw at it if you want to implement its API here and there for custom 
 transformations, and while I am 100% sure it can handle [n] index notation I 
 am about 90% sure it also handles indices as property names as you have 
 described (.n)--if not, that is pluggable.  But this isn't the Morph list 
 and, as you said, you made a management decision not to pursue it.  As a 
 Morph team member I will take your documentation didn't look very helpful 
 criticism under advisement as well.


Yeah its out-of-date

http://tinyurl.com/dhsupb

Niall

 Regards,
 Matt

 Regards
 Adam

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [beanutils] converting HTTP params into an arbitrary object model

2009-02-25 Thread Niall Pemberton
On Wed, Feb 25, 2009 at 12:53 PM, Adam Hardy
ahardy.str...@cyberspaceroad.com wrote:
 Niall Pemberton on 25/02/09 10:54, wrote:

 On Tue, Feb 24, 2009 at 3:09 PM, Matt Benson gudnabr...@yahoo.com wrote:

 --- On Sat, 2/21/09, Adam Hardy wrote: The problem is that there are
 that
 many little details to check for, e.g. can it handle sets, can it deduce
 the javabean items on generics, can it handle indexed lists of .0, .1,
 .2 notation etc

 Morph is not generics-enabled; it can handle most of your basic
 non-generic
 etc etc [snipped]

 Yeah its out-of-date

 http://tinyurl.com/dhsupb

 Hi Niall,
 were you skiing? that's the only valid excuse I'll accept for your tardy
 response I'm afraid. Well ok i might let you off for anything involving
 hospitalisation, death or taxes ;)

Yes all of those I'm afraid!

 Is there any kind of roadmap for beanutils to bring in decent locale
 handling and more refined converter mapping? (mapping a converter to a
 property, not just a complete class)

None that I know of.

 I like beanutils - some people say it's got a (inter-)face only a mother
 could love, but I think it's OK.

:)

Niall

 regards
 Adam

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: [BeanUtils] Possible to hook in a different getter/setter naming convention?

2009-01-04 Thread Niall Pemberton
On Fri, Jan 2, 2009 at 11:13 PM, kennardconsulting
rich...@kennardconsulting.com wrote:

 Dear All,

 I am enjoying using Commons BeanUtils with all its converters and
 'foo.bar.baz' path notation goodness.

 I was wondering if it was possible to retain this goodness whilst changing
 to a different getter/setter naming convention? Instead of 'getFoo()',
 'setFoo(x)', I'd like to use 'foo()' and 'foo_$eq(x)' which is the native
 Scala naming convention.

BeanUtils uses Introspector[1] at its heart[2] to discover the
properties of a bean - which is based on the java bean spec and tied
to the get/set naming convention for methods. So if you want to change
this behaviour you would need to start by overriding the
getPropertyDescriptors() method in PropertyUtilsBean

Niall

[1] http://java.sun.com/j2se/1.4.2/docs/api/java/beans/Introspector.html
[2] 
http://commons.apache.org/beanutils/xref/org/apache/commons/beanutils/PropertyUtilsBean.html#956


 Is there some method/interface to override to make this change without
 impacting everything else?

 Regards,

 Richard.

-
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org



Re: SCXML and commons survay

2008-12-05 Thread Niall Pemberton
On Fri, Dec 5, 2008 at 1:48 PM, Torsten Curdt [EMAIL PROTECTED] wrote:
 Hey Karl

 I am a developer here in Germany,
 and we (the software team I am working for) are considering to use the SCXML
 and the Commons libraries for a Prove of Concept Prototype,
 and I would like to know if SCXML and the Common libraries
 listed below are used in other Open Source or Commercial projects?

 commons-logging-1.1.1.jar
 commons-scxml-0.9.jar
 commons-jexl-1.1.jar
 commons-digester-1.8.jar
 commons-beanutils-1.8.0.jar

 In other words who is using SCXML and commons?

 Can't say a word about SCXML ...but in general commons libraries are
 used in many(!) projects. Almost 20% of all artifacts in the central
 maven repo have a dependency to commons.

 Don't expect to get a list of projects with the exact versions here though.

There is this:

http://mvnrepository.com/artifact/commons-scxml/commons-scxml/

which is only showing one project which uses 0.6 version - Shale

Niall

 cheers
 --
 Torsten

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



Re: JXPath and LazyDynaBeans

2008-11-21 Thread Niall Pemberton
On Thu, Nov 20, 2008 at 12:10 AM, Andrew Hughes [EMAIL PROTECTED] wrote:
 Hi All,

 There are so many options here, I'm not sure which one is the easiest/best
 solution. I've got a data structure which I am using to populate (a
 hierarchy of)  LazyDynaBean's so that we can run JXPath across it. It's
 working perfectly, until I try and introduce duplicate key entries (i.e. a
 node can have 1 children of the same name).

 My example heirarchy I wish to build is this...

 /
 /car='Ferrari'
 /car='Porsche'
 /car=Lamborghini'


 In xml it might look like...

 root
carFerrari/car
carPorsche/car
carLamborghini/car
 /root


 Anyway, to cut to the chase. I have multiple 'car' property entries and I am
 trying to run the follwing code:

 LazyDynaBean lazyDynaBean = new LazyDynaBean();
 JXPathContext jxPathContext = JXPathContext.newContext(lazyDynaBean);
 lazyDynaBean.set(car,0, Ferrari);
 lazyDynaBean.set(car,1, Porsche);
 lazyDynaBean.set(car,2, Lamborghini);
 Iterator i = jxPathContext.iteratePointers(car);
 while(i.hasNext()){
 System.out.println(Got pointer: +i.next().toString());
 }


 The error is:

 Exception in thread main java.lang.ArrayIndexOutOfBoundsException: 0
 at
 org.apache.commons.jxpath.ri.model.dynabeans.DynaBeanPropertyPointer.getPropertyNames(DynaBeanPropertyPointer.java:84)
 at
 org.apache.commons.jxpath.ri.model.beans.PropertyIterator.prepareForIndividualProperty(PropertyIterator.java:270)
 at
 org.apache.commons.jxpath.ri.model.beans.PropertyIterator.setPositionIndividualProperty(PropertyIterator.java:154)
 at
 org.apache.commons.jxpath.ri.model.beans.PropertyIterator.setPosition(PropertyIterator.java:139)
 at
 org.apache.commons.jxpath.ri.axes.ChildContext.setPosition(ChildContext.java:101)
 at
 org.apache.commons.jxpath.ri.axes.ChildContext.nextNode(ChildContext.java:87)
 at
 org.apache.commons.jxpath.ri.EvalContext.performIteratorStep(EvalContext.java:155)
 at org.apache.commons.jxpath.ri.EvalContext.hasNext(EvalContext.java:115)
 at rnd.JXPathRND.App.main(App.java:24)


 How am I supposed to populate the DynaBean so that it can contain more than
 one 'car' property?

I would have expected the lazy DynaBean to contain a list of Strings -
I would check if it does. If it does then the issue is in JXPath.

Niall

 Also, I would prefer not to have to specify the index 0,1,2 if that is at
 all possible.

 Thanks in advance.


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



Re: beanutils copy to ignore null properties

2008-10-13 Thread Niall Pemberton
On Mon, Oct 13, 2008 at 7:25 PM, miro [EMAIL PROTECTED] wrote:

 I have Bean Test
 with properties   A and B

 An instance of  Test  TestA has value for A   and B is null.
 another intance of Test  TestB  has value for B and A is null .
 now  when I call copyProperties BeanUtils.copyProperties(TestA, TestB)
 TestA
  property A will get null
 and Propetrty B will be B

 instead I want beanUtils to update TestA  just by copying non null
 properties is it possible ?

This isn't provided by BeanUtils, but you could use BeanUtils to build
this kind of *merge functionality.

Niall

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



Re: Commons-beanutils indexdProperty error

2008-10-10 Thread Niall Pemberton
On Fri, Oct 10, 2008 at 6:28 AM, Deep D [EMAIL PROTECTED] wrote:
 Hi,

 I am very new to the beanutils.
 I am trying to set value to an array list using indexed properties.

 It is throwing the following error
 Exception in thread main java.lang.
 IndexOutOfBoundsException: Index: 0, Size: 0
at java.util.ArrayList.rangeCheck(ArrayList.java:572)
at java.util.ArrayList.set(ArrayList.java:365)
at 
 org.apache.commons.beanutils.PropertyUtilsBean.setIndexedProperty(PropertyUtilsBean.java:1711)

 Here is my  code

BeanUtils doesn't automatically grow arrays/Lists (except for
LazyDynaBean) - so while you can use the indexed setter to set an
indexed property the List needs to have elements that size already,
otherwise you see exactly the error you're getting. So you have a
number of ways you can resolve this:

1) Ensure that your List is always large enough - so if for example
you know that there will never been more than five addresses, then
initialize the list with five empty/null elements [not that I'm
recommending this - hacky]

2) Provide indexed getters/setters in your object (BeanUtils will use
if available these rather than the List getters/setters) and implement
lazy list growth. So in your address example something like:

https://java.sun.com/docs/books/tutorial/javabeans/properties/indexed.html

public Address getAddr(int idx) {
while (idx = addr.size()) {
addr.add(new Address()); //dynamically grow list to accomodate
}
return addr.get(idx);
}

public void setAddr(int idx, Address element) {
while (idx = addr.size()) {
addr.add(new Address()); //dynamically grow list to accomodate
}
this.addr.set(idx, element);
}

3) Use a lazy list to hold your addresses - for example:
http://commons.apache.org/collections/api-release/org/apache/commons/collections/list/LazyList.html

4) Use a LazyDynaBean, which supports lazy list/array growth out of the box
http://commons.apache.org/beanutils/v1.8.0/apidocs/org/apache/commons/beanutils/package-summary.html#dynamic.lazy

Niall

 import java.util.ArrayList;
 import java.util.List;

 public class Employee {

private String name;

private int id;

private String dept;

private ListAddress addr=new ArrayListAddress();

public ListAddress getAddr() {
return addr;
}

public void setAddr(ListAddress addr) {
this.addr = addr;
}

public String getName() {
return name;
}

public void setName(String name) {
this.name = name;
}

public int getId() {
return id;
}

public void setId(int id) {
this.id = id;
}

public String getDept() {
return dept;
}

public void setDept(String dept) {
this.dept = dept;
}

 }



 public class Address {




private String line;

private String aptno;

public String getLine() {
return line;
}

public void setLine(String line) {
this.line = line;
}

public String getAptno() {
return aptno;
}

public void setAptno(String aptno) {
this.aptno = aptno;
}


 }


 public void indexdPropTest(){
Employee emp=new Employee();
Address addr=new Address();
try {
PropertyUtils.setSimpleProperty(addr, line,36777 );
PropertyUtils.setIndexedProperty(emp,addr,0,addr);
} catch (IllegalAccessException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (InvocationTargetException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (NoSuchMethodException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}


}

 Can somebody advise me if anything wrong with this? I had tried replacing 
 arraylist with an array and it was successful.

 Thanks,
 D




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



Re: BeanUtils copyProperties with null Date

2008-10-03 Thread Niall Pemberton
On Fri, Oct 3, 2008 at 7:30 PM, Tom Spencer [EMAIL PROTECTED] wrote:
 Hi,

 I'm new to BeanUtils and I would firstly like to say a big thank you - this 
 is such a useful utility and has saved me countless hours of my time!

 I am, however, running into a difficulty. I am using BeanUtils 1.8.0 to copy 
 a java.util.Date property from one bean to another. I have noticed that if 
 the java.util.Date property is set to null, when I call 
 BeanUtils.copyProperties() I get the following error:

 Exception in thread main org.apache.commons.beanutils.ConversionException: 
 No value specified for 'Date'
at 
 org.apache.commons.beanutils.converters.AbstractConverter.handleMissing(AbstractConverter.java:310)
at 
 org.apache.commons.beanutils.converters.AbstractConverter.convert(AbstractConverter.java:136)
at 
 org.apache.commons.beanutils.converters.ConverterFacade.convert(ConverterFacade.java:60)
at 
 org.apache.commons.beanutils.BeanUtilsBean.convert(BeanUtilsBean.java:1074)
at 
 org.apache.commons.beanutils.BeanUtilsBean.copyProperty(BeanUtilsBean.java:437)
at 
 org.apache.commons.beanutils.BeanUtilsBean.copyProperties(BeanUtilsBean.java:286)
at 
 org.apache.commons.beanutils.BeanUtils.copyProperties(BeanUtils.java:137)
at Main.main(Main.java:10)


 I have copied the sample code for the two beans and a test main class below. 
 Could anybody else verify that this is occurring too? I am using 
 beanutils-1.8.0.

You have a choice of two flavours for copying properties in BeanUtils:
1) Usng PropertyUtils copyProperties() method[1] - this just copies
any properties unchanged
2) Using BeanUtils  copyProperties() method[2] - copies AND converts
properties - so for example, if theres a property called foo of type
String in the source and a property called foo of type Integer in
the destination then it tries to convert the String to an Integer
using the Converter registered for Integers.

If you don't need conversion then you can switch to using
PropertyUtils. If however you have some conversion needs, but you
don't want it to throw an exception when a value is null (which is
the default behaviour) - then you can configure a converter for Date
which has a default value. So for example, if you wanted a default of
null for Dates, then something like the following:

java.util.Date defaultValue = null;
DateConverter converter = new DateConverter(defaultValue);
ConvertUtils.register(converter, java.util.Date.class);

Then when you call BeanUtils.copyProperties() it should no longer
throw an exception.

Niall

[1] http://tinyurl.com/4rc5ho
[2] http://tinyurl.com/44csva


 Tom

 -

 import java.util.Date;

 public class Bean1 {

private Date date;

public Bean1() {
super();
}

public Date getDate() {
return date;
}

public void setDate(Date date) {
this.date = date;
}

 }

 -

 import java.util.Date;

 public class Bean2 {

private Date date;

public Bean2() {
super();
}

public Date getDate() {
return date;
}

public void setDate(Date date) {
this.date = date;
}

 }

 -

 import org.apache.commons.beanutils.BeanUtils;

 public class Main {

public static void main(String[] args) throws Exception {
Bean1 bean1 = new Bean1();
bean1.setDate(null);
Bean2 bean2 = new Bean2();

BeanUtils.copyProperties(bean2, bean1);

System.out.println(bean2.getDate());

}

 }





 _
 Discover Bird's Eye View now with Multimap from Live Search
 http://clk.atdmt.com/UKM/go/111354026/direct/01/

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



Re: PropertyUtils.copyProperties() and inherited classes

2008-09-23 Thread Niall Pemberton
On Tue, Sep 23, 2008 at 8:46 AM,  [EMAIL PROTECTED] wrote:
 Hi @all,

 as it seems, the PropertyUtils.copyProperties() as well as
 BeanUtils.copyProperties() only do a copy on class-level.
 As I would like to reuse my copy-methods for an inherited
 class-structure I would like to ask if there is also a chance to do a
 full-object copy for inherited classes for all properties.

 ==
 Example:

 public class Class1 {
private String attribute1;
 }

 public class Class2  extends Class1 {
private String attribute2;
 }

 public class Business {

public static copy(Class1 source, Class1 dest) {
PropertyUtils.copyProperties(source, dest)
}
 }
 ==

 If I call Business.copy() with 2 instances of Class1, attribute1 is
 perfectly copied. But if I call the same method with 2 instances of
 Class2, only attribute1 is copied although I would also like to copy
 attribute2 as well. Any chance to do that?

It does do this - but looks like you have the parameters the wrong way
round, try

   PropertyUtils.copyProperties(dest, source)

 Furthermore I realized that enumerations are not copied, too. Is there a
 chance to copy the bean-instance including enumerations?

BeanUtils doesn't support JDK 1.5 features and it doesn't look very
likely it will do so since its pretty much in maintenance mode.

Niall

 Thanks for your help

 Thomas




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



Re: [Chain] Parametizing commands?

2008-09-05 Thread Niall Pemberton
On Fri, Sep 5, 2008 at 5:49 PM,  [EMAIL PROTECTED] wrote:

 I'm looking for a way to decouple the context keys used in a command from
 the actual context keys used at runtime. Here's an example:

 Here's a really simple command  that just concatenates two strings from the
 context - the keys are A and B and the concatenated output goes in C:

 public class Concat implements Command
 {
@Override
public boolean execute(Context context) throws Exception
{
context.put(C, (String) context.get(A) + (String)
 context.get(B));
return false;
}
 }

 Let's say I need to create a chain that uses this command, but the other
 commands leading up to this one leave the two strings that need to be
 joined the context under the keys FIRST_NAME and LAST_NAME, and the result
 is expected to be in FULL_NAME for the next step in processing. So now I
 have to create two more commands: one to move FIRST_NAME to A and LAST_NAME
 to B, so that the strings are in the right places for my Concat command,
 and then another to follow that moves C to LAST_NAME.

 That's not very nice - I now have three commands to do the job of one. If I
 need to use Concat somewhere else but using different keys again (combining
 DIRECTORY and FILE to create PATH, say) I have to create yet more commands
 just to move things around so that I can re-use the command that does the
 actual work. And in fact in the application I've been developing something
 like a third of the commands in the app are just to do this kind of
 data-shuffling, and I have command chains that are twice as long as they
 really should be.

 What I'd like to be able to do is provide some kind of mapping from the
 label keys used by my command code, to the real keys that get used at
 runtime. As an example, I might want to represent my chain something like
 this in XML:

  command name=Concat
map label=A to=FIRST_NAME /
map label=B to=LAST_NAME /
map label=C to=FULL_NAME /
  /command
  command name=Concat
map label=A to=DIRECTORY /
map label=B to=FILE /
map label=C to=PATH /
  /command

 I could do this myself *if* there was a way to parametize individual
 command references in a chain something like this, but as far as I can tell
 there is no such option in Chain as it is right now.

The sample webapp(s) has an example of exactly this - theres an
example forward command where the actual forward is specified as a
property:

http://svn.apache.org/repos/asf/commons/proper/chain/trunk/apps/example1/src/main/java/org/apache/commons/chain/apps/example/ForwardCommand.java

Then in the chain config you specify the fowards property:

http://svn.apache.org/repos/asf/commons/proper/chain/trunk/apps/example1/src/main/webapp/WEB-INF/chain-config.xml

Niall

 It strikes me, having used Chain for a while, that I am probably not the
 only one to have come across the general problem of having fixed keys in
 Commands referring to movable data in Contexts. What I've described here
 is a potential solution but I don't think it'll work because Chain doesn't
 support being able to attach parameter sets to Command references. Is there
 another solution out there?

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



Re: isEscaped

2008-09-03 Thread Niall Pemberton
On Tue, Sep 2, 2008 at 7:28 PM, Gabriel Reis [EMAIL PROTECTED] wrote:
 Hi,

 Is there any tool to verify if a String is escaped? Something like this:

 assertFalse( StringEscapeUtils.isHtmlEscaped(btext/b) );

 assertTrue( StringEscapeUtils.isHtmlEscaped(lt;bgt;textlt;/bgt;) );

Perhaps one way to do this is to use the StringEscapeUtils's
unescapeHtml() method and compare if the result equals the original.

something like...

if (value.equals(StringEscapeUtils.unescapeHtml(value))) {
...
}

http://commons.apache.org/lang/api-release/org/apache/commons/lang/StringEscapeUtils.html#unescapeHtml(java.lang.String)

Niall

 []s
 Gabriel


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



[ANNOUNCEMENT] Commons BeanUtils 1.8.0 Released

2008-09-01 Thread Niall Pemberton
The Apache Commons project is pleased to announce the release of Commons 
BeanUtils 1.8.0. Commons BeanUtils provides easy-to-use wrappers around 
the Reflection and Introspection APIs provided by the Java language.


BeanUtils 1.8.0 is binary compatible with version 1.7.0 and contains a 
number of bug fixes and enhancements. Full details of changes are 
available in the Release Notes:


http://commons.apache.org/beanutils/v1.8.0/RELEASE-NOTES.txt

Commons BeanUtils is available in either binary or source form from the 
following download page:


http://commons.apache.org/beanutils/download_beanutils.cgi

For more information on Commons BeanUtils, visit the project home page:

http://commons.apache.org/beanutils/

- Niall Pemberton -
on behalf of the Apache Commons community





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



Re: Commons validator

2008-08-29 Thread Niall Pemberton
On Fri, Aug 29, 2008 at 5:36 AM, Vinay Binny [EMAIL PROTECTED] wrote:
 Hi all,

 I see a compareDates method in the DateValidator class of the routine
 package, I was wondering if I could use it directly in my
 validator-rules.xml by specifying something like:

 validator name=compareDate

 classname=org.apache.commons.validator.DateValidator

 method=compareDates
 but I had no luck figuring out how to di it.

 OR

 Should I be using these routine classes to develop a custom validation rule?

You need to develop a custom routine since that method (and other
similar ones) return an integer representing equal, less than and
greater than in the same style as the Comparator implementations:

http://java.sun.com/j2se/1.5.0/docs/api/java/util/Comparator.html

So this could be used to develop validation rules for less than, less
than or equal, equal, greater than, greater than or equal

Niall

 Thanks,

 Vinay.

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



Re: Is Common FileUpload 1.2.1 compatible with JDK 1.3

2008-08-15 Thread Niall Pemberton
On Fri, Aug 15, 2008 at 1:18 PM, Peng Ming [EMAIL PROTECTED] wrote:

 Hi all,
  I'm still using JDK 1.3 for a very old project. Just want to add Apache
 Common FileUpload to that project to implement the Upload function. Is the
 latest FileUpload version, that is 1.2.1, working fine in JDK 1.3? Thanks
 for any information.

Yes, although the release was built using JDK 1.6 it has the
source/target compiler options set to 1.3 and release was tested on
JDK 1.3 before it was approved (in fact this was one of the issues
with the previous release candidate) - see
http://markmail.org/message/cxao2pr57mtz3whh

Niall

 --
 View this message in context: 
 http://www.nabble.com/Is-Common-FileUpload-1.2.1-compatible-with-JDK-1.3-tp18997705p18997705.html
 Sent from the Commons - User mailing list archive at Nabble.com.

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



Re: JDK 1.4 EOL date is October

2008-07-02 Thread Niall Pemberton
On Wed, Jul 2, 2008 at 10:16 AM, Brosnan, Michael
[EMAIL PROTECTED] wrote:

 The date for JDK 1.4 bing EOL is October 2008, see
 http://java.sun.com/j2se/1.4.2/

 Are there plans in place to update the commons apache components to build
 with JDK 1.5 instead?

Its being done on a component-bycomponent basis. The following list
may not be complete, but this is the state-of-play that I know of:

1) Collections - has had a JDK 1.5 branch for quite some time, not
very active atm
http://svn.apache.org/repos/asf/commons/proper/collections/branches/collections_jdk5_branch/

2) Configuration - Version 2.0 branch requires JDK 1.5:
http://svn.apache.org/repos/asf/commons/proper/configuration/branches/configuration2_experimental/

3) IO - last release (1.4) was JDK 1.4 compatible, but the current
trunk (and the next release, probably 2.0) now requires JDK 1.5

4) Lang - discussed recently on the dev list:
http://markmail.org/message/k36vrkgupiewg3qx

5) Math - Version 2.0 branch requires JDK 1.5:
http://svn.apache.org/repos/asf/commons/proper/math/branches/MATH_2_0/

6) Net - Version 2.0 branch requires JDK 1.5:
http://svn.apache.org/repos/asf/commons/proper/net/branches/NET_2_0/

7) SCXML - J6 branch requires JDK 1.6
http://svn.apache.org/repos/asf/commons/proper/scxml/branches/J6/

Niall

 Regards

 Mike Brosnan


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



Re: Commons IO FileUtils question

2008-06-30 Thread Niall Pemberton
On Mon, Jun 30, 2008 at 8:15 PM, Eric Hamacher
[EMAIL PROTECTED] wrote:
 Hello:

 I took a file on my filesystem, copied and renamed it.  I took the two
 files and compared them using FileUtils.contentEquals(File, File).  In
 this case, shouldn't the method return true?  If not, when would it
 return true?

Yes it should return true. Can you use a debugger to find out which
line in FileUtils is returning false? Also best to say which version
of Commons IO you are using.

Niall


 Thanks



 Regards,

 Eric Hamacher

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



[ANNOUNCE] Commons Chain 1.2 Released

2008-06-03 Thread Niall Pemberton
The Apache Commons project would like to announce the immediate 
availability of Commons Chain 1.2.


Commons Chain provides an implementation of the GoF Chain of 
Responsibility pattern.


Commons Chain 1.2 contains a small number bug fixes and is the first 
OSGi-enabled release. Details can be found in the release notes:


 http://commons.apache.org/chain/changes-report.html

Commons Chain is available in either binary or source form from the 
following downloads page:


 http://commons.apache.org/chain/download_chain.cgi

For more information on Commons Chain, visit the project home page:

 http://commons.apache.org/chain/

-Niall Pemberton
 on behalf of the Apache Commons community



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



Re: [cli2] Negative number arguments seen as options

2008-05-30 Thread Niall Pemberton
On Fri, May 30, 2008 at 8:12 PM, Emmanuel Bourg [EMAIL PROTECTED] wrote:
 Niall Pemberton a écrit :

 How can Avalon CLI be released - that projects closed?

 The Avalon CLI code was imported in a branch of Commons CLI:

 https://svn.apache.org/repos/asf/commons/proper/cli/branches/avalon-implementation/

Ah OK - but were really not going to release that -would seem crazy to
potentially have three different flavours out there to support (CLI1,
CLI2, CLI-avalaon).

Niall

 Emmanuel Bourg

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



Re: Is JXPath project abandoned?

2008-05-19 Thread Niall Pemberton
On Mon, May 19, 2008 at 4:13 PM, Adrian Mitev
[EMAIL PROTECTED] wrote:
 Is the project still active?

Matt Benson has been working on it recently:
http://markmail.org/search/?q=jxpath%20list%3Aorg.apache.commons.commits%2F

...and has been working on a 1.3 release:
http://markmail.org/message/rlet6az5r5nlqji4
http://markmail.org/message/mx27ba7osqpnmxqd

Niall

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



Re: About commons codec ver 1.1 and export control rules

2008-05-19 Thread Niall Pemberton
On Mon, May 19, 2008 at 3:15 PM, Trevisson Cristina
[EMAIL PROTECTED] wrote:
 Dear All,

 Would you be so kind to help me in answering the following question ?
 Does common codec ver 1.1 contain symmetric cryptographic algorithms
 employing a key length in excess of 56 bits or an asymmetric algorithm
 ?
 In general is there any document that gives the export control
 classification for Commons Codec ?

There is documentation on this for the whole ASF here:

http://www.apache.org/licenses/exports/

Theres an Apache Commons section - and as Codec is not listed there
then AFAIK that means there is no cryptographic functionality in
Codec.

Niall

Niall

 Many thanks in advance for your help,
 Cristina

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



Re: [beanutils] getPropertyType() on java.util.Map

2008-03-22 Thread Niall Pemberton
On Fri, Mar 21, 2008 at 2:43 PM, Doug Breaux
[EMAIL PROTECTED] wrote:
 The following property:

  myMap(myKey)

  with a bean property of:

  new java.util.HashMapString, Long()

  returns java.util.Map from PropertyUtils.getPropertyType()

  I was expecting Long.  Map seems like a bug.

Well it depends on the getters/setters you have defined. If you have

  public Map getMyMap()
  public void setMyMap(Map)
  public Long getMyMap(String)
  public void setMyMap(String, Long)

Then it should return a Long as the type.

Niall

  Note that getPropertyType() with a property name of simply myMap also
  returns java.util.Map, which is what I would expect.

  Doug

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



Re: BeanUtils: dirty checking

2008-03-05 Thread Niall Pemberton
On Wed, Mar 5, 2008 at 3:33 PM, Paul Benedict [EMAIL PROTECTED] wrote:
 This question is about BeanUtils 1.8.

  Does any functionality exist to compare two beans of the same type to
  determine whether (a) it is dirty and (b) a list/set of differences of
  properties?

Not at the moment, but I think theres an open JIRA ticket for this
kind of thing somewhere:

http://commons.apache.org/beanutils/issue-tracking.html

I have a modified lazy DynaBean implementation that can track
changes (you switch on/off the tracking as required) and you can get a
list of modified properties and their current and original values.
Works pretty well for us

Niall

  Paul


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



Re: Enhanced DirectoryWalker

2008-02-20 Thread Niall Pemberton
This was been raised before here: http://tinyurl.com/3dmkcl

The one thing that makes me hesitate is it could be confusing since
the user might expect the Collection to be sorted. Anyway, it needs to
be filed as an enhancement request in JIRA - preferably with a patch -
since thats easier to see the proposed changes and to apply:

http://commons.apache.org/io/issue-tracking.html

Niall

On Wed, Feb 20, 2008 at 10:10 PM, Jeff higgins [EMAIL PROTECTED] wrote:

  Hi,
  I would like to request a feature enhancement for
  org.apache.commons.io.DirectoryWalker.

  add sort comparator to walk method

  Thank you for any consideration.
  Jeff Higgins



   private final FileFilter defaultFilter;
   private FileFilter currentFilter;
   private final int defaultDepthLimit;
   private int currentDepthLimit;
   private final Comparator defaultComparator;
   private Comparator currentComparator;

   protected DirectoryWalker() {
 this(null, null, -1);
   }


   protected DirectoryWalker(FileFilter defaultFilter,
   Comparator defaultComparator, int defaultDepthLimit) {
 this.defaultFilter = defaultFilter;
 this.currentFilter = this.defaultFilter;
 this.defaultDepthLimit = defaultDepthLimit;
 this.currentDepthLimit = this.defaultDepthLimit;
 this.defaultComparator = defaultComparator;
 this.currentComparator = this.defaultComparator;
   }


   protected DirectoryWalker(IOFileFilter directoryFilter,
   IOFileFilter fileFilter, Comparator defaultComparator,
   int depthLimit) {
 if (directoryFilter == null  fileFilter == null) {
   this.defaultFilter = null;
 } else {
   directoryFilter = (directoryFilter != null ? directoryFilter
   : TrueFileFilter.TRUE);
   fileFilter = (fileFilter != null ? fileFilter : TrueFileFilter.TRUE);
   directoryFilter = FileFilterUtils.makeDirectoryOnly(directoryFilter);
   fileFilter = FileFilterUtils.makeFileOnly(fileFilter);
   this.defaultFilter = FileFilterUtils.orFileFilter(directoryFilter,
   fileFilter);
 }
 this.currentFilter = this.defaultFilter;
 this.defaultDepthLimit = depthLimit;
 this.currentDepthLimit = this.defaultDepthLimit;
 this.defaultComparator = defaultComparator;
 this.currentComparator = this.defaultComparator;
   }


   protected final void walk(File startDirectory, Collection results)
   throws IOException {
 if (startDirectory == null) {
   throw new NullPointerException(Start Directory is null);
 }
 try {
   handleStart(startDirectory, results);
   walk(startDirectory, 0, results);
   handleEnd(results);
 } catch (CancelException cancel) {
   handleCancelled(startDirectory, results, cancel);
 }
   }


   private void walk(File directory, int depth, Collection results)
   throws IOException {

 checkIfCancelled(directory, depth, results);
 if (handleDirectory(directory, depth, results)) {
   handleDirectoryStart(directory, depth, results);
   int childDepth = depth + 1;
   if (currentDepthLimit  0 || childDepth = currentDepthLimit) {
 checkIfCancelled(directory, depth, results);
 File[] childFiles = (currentFilter == null ? directory.listFiles()
 : directory.listFiles(currentFilter));
 if (childFiles == null) {
   handleRestricted(directory, childDepth, results);
 } else {
   if (currentComparator != null)
 Arrays.sort(childFiles, currentComparator);
   for (int i = 0; i  childFiles.length; i++) {
 File childFile = childFiles[i];
 if (childFile.isDirectory()) {
   walk(childFile, childDepth, results);
 } else {
   checkIfCancelled(childFile, childDepth, results);
   handleFile(childFile, childDepth, results);
   checkIfCancelled(childFile, childDepth, results);
 }
   }
 }
   }
   handleDirectoryEnd(directory, depth, results);
 }
 checkIfCancelled(directory, depth, results);
   }

   public FileFilter getDefaultFilter() {
 return defaultFilter;
   }

   public FileFilter getCurrentFilter() {
 return currentFilter;
   }

   public void setCurrentFilter(FileFilter filter) {
 this.currentFilter = filter;
   }

   public Comparator getDefaultComparator() {
 return defaultComparator;
   }

   public Comparator getCurrentComparator() {
 return currentComparator;
   }

   public void setCurrentComparator(Comparator comparator) {
 this.currentComparator = comp;
   }

   public int getDefaultDepthLimit() {
 return defaultDepthLimit;
   }

   public int getCurrentDepthLimit() {
 return currentDepthLimit;
   }

   public void setCurrentDepthLimit(int depth) {
 this.currentDepthLimit = depth;
   }



  --
  View this message in context: 
 http://www.nabble.com/Enhanced-DirectoryWalker-tp1566p1566.html
  Sent from the Commons - User mailing list archive 

Re: [BEANUTILS] LocaleConvertUtilsBean convert method with null locale

2008-02-15 Thread Niall Pemberton
On Fri, Feb 15, 2008 at 1:39 PM, Lucian Chirita [EMAIL PROTECTED] wrote:
 Is the LocaleConvertUtilsBean.convert(String value, Class clazz, Locale
  locale, String pattern) method supposed to accept null Locale arguments?

  This generally works, as the locale is used to resolve a converter, and
  the lookup(Locale locale) method checks whether the argument is null and
  uses the default locale in this case.

  However, when debug statements are enabled for LocaleConvertUtilsBean,
  the convert methods fails with NullPointerException on null Locale as
  the debug statement does locale.toString().

  Could this inconsistency be considered a bug?

Yes please file a bug report in JIRA:

http://commons.apache.org/beanutils/issue-tracking.html

Thanks

Niall

  Thanks,
  Lucian

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



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



[ANNOUNCE] Commons IO 1.4 Released

2008-01-21 Thread Niall Pemberton
The Apache Commons team is pleased to announce the release of Commons IO 1.4.

Commons IO is a library of utilities to assist with developing IO
functionality. See the IO website for more details:
http://commons.apache.org/io/

This 1.4 release contains a few bugfixes and a number of new features
and improvements including several new stream implementations, a new
package of file comparators, a regular expression filter and additions
to the file utilities. See the release notes for full details:
http://commons.apache.org/io/upgradeto1_4.html

Download:
http://commons.apache.org/downloads/download_io.cgi

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



Re: [daemon] where can i find procrun

2007-12-06 Thread Niall Pemberton
On Dec 6, 2007 12:11 PM,  [EMAIL PROTECTED] wrote:
 I hope this Mail gets where it should get! (Some people have a problem to
 document something where everyone can find it)

 can anyone help me please?

From the archives:
  http://commons.markmail.org/message/3ks6333gdkwuttru
  http://commons.markmail.org/message/k2mwxzxoq5s2viwl

Tomcat user list:
http://tomcat.apache.org/lists.html

Niall

 sebb [EMAIL PROTECTED] schrieb am 06.12.2007 12:59:01:


  I don't know, but perhaps adding the commons project to the subject
  (as required on this mailing list) will alert someone on that
  project...
 
  On 06/12/2007, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
   Hello is there someone who could tell me where to get the
 procrun.exe?
  
  
   Mit freundlichen Gruessen / Best regards
  
   Rene Dolezal, Organisation 5
  
   Julius Blum GmbH, Beschlaegefabrik, A-6973 Hoechst
   FN 62067 a  -  LG Feldkirch
   phone: +43 5578 705 3815
   fax: +43 5578 705 5 3815
   mailto:[EMAIL PROTECTED]
   http://www.blum.com
   http://www.dynamicspace.com
  
   [EMAIL PROTECTED] schrieb am 05.12.2007 14:59:21:
  
,
   
Hello,
   
mybe i'm stupid or i'm blind but i can't find a download for the
procrun.exe.
or am i running the wrong version of windows which doesen't contain
procrun? (I'm running Windows Server 2003R2)
   
This page http://jakarta.apache.org/commons/daemon/procrun.html
 talks
about the usage of procrun (no Download here).
And on the page
 http://jakarta.apache.org/commons/daemon/binaries.html
   in
the chapter What to do to get the excutable (typo in the page!!)
 this
   is
the only information i get there: The procrun.exe has to be
 installed as
   a
service. (See procrun for more information.
I like this backlinking seems like i'm stuck in an endless loop.
 Isn't
this odd for you too?
   
On the binaries page
 http://www.apache.org/dist/commons/daemon/binaries/
  
there is no distribution for Windows!
   
It shouldn't be so hard to provide a little How to get started
instruction for newbees like me!
   
btw: after googleing i found nothing to download! Hell this can't be
 so
complex! Do i have to compile this thing for myself, but how?
   
   
Mit freundlichen Gruessen / Best regards
   
Rene Dolezal, Organisation 5
   
Julius Blum GmbH, Beschlaegefabrik, A-6973 Hoechst
FN 62067 a  -  LG Feldkirch
phone: +43 5578 705 3815
fax: +43 5578 705 5 3815
mailto:[EMAIL PROTECTED]
http://www.blum.com
http://www.dynamicspace.com
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 


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



Re: Commons validator error

2007-11-09 Thread Niall Pemberton
On Nov 9, 2007 4:47 PM, Nuno Martins [EMAIL PROTECTED] wrote:
 Hi all,

 I'm developing a commons-validator (with struts) standalone application.

Not sure what you mean by standalone and with Struts. Are you
using the standard built-in Struts validation? From the error below I
guess not - I can only see one way this could have happened:

1) A null reference was passed to the validateMask() method where it
expected an ActionMessages object.
2) The null  ActionMessages caused a NullPointerException to be
thrown on line 235 of FieldChecks in the validateMask() method (where
it tries to add a message to the ActionMessages object).
3) That NullPointerException was caught by the try/catch block in the
validateMask() method so it called the processFailure() method.
4) The processFailure() method logged the message mask validation
failed for property xpto: java.lang.NullPointerException
5) The processFailure() threw another NullPointerException on line
1323 when it tried to add a message to ActionMessages
6) ValidatorAction caught the 2nd NullPointerException and logged the
message Unhandled exception thrown during validation: null  + stack
trace

Perhaps I'm wrong, but this is the only explanation I can see. If I am
right then it looks like you are not using the standard build-in
Struts validation and the problem is you haven't configured the
Validator instance you're using with an ActionMessages object.
Fixing that issue should resolve the problem - something like:

validator.setParameter(ACTION_MESSAGES_PARAM, errors);

Best place to look on initializing Validator is in the validate()
method of ValidatorForm[1] and initValidator() method of Resources[2]

[1] 
http://svn.apache.org/repos/asf/struts/struts1/trunk/core/src/main/java/org/apache/struts/validator/ValidatorForm.java
[2] 
http://svn.apache.org/repos/asf/struts/struts1/trunk/core/src/main/java/org/apache/struts/validator/Resources.java

Niall

 Since  using  new versions 1.3.1 (commons-validator) and 1.3.9 (struts),
 an error occurred.


 [WARN ][2007-11-09
 16:43:17,039][org.apache.struts.util.PropertyMessageResources]:
 Resource org/apache/struts/validator/LocalStrings_en_GB.properties Not
 Found.
 [WARN ][2007-11-09
 16:43:17,039][org.apache.struts.util.PropertyMessageResources]:
 Resource org/apache/struts/validator/LocalStrings_en.properties Not Found.
 [ERROR][2007-11-09
 16:43:17,041][org.apache.struts.validator.FieldChecks]: mask validation
 failed for property xpto: java.lang.NullPointerException
 [ERROR][2007-11-09
 16:43:17,043][org.apache.commons.validator.ValidatorAction]: Unhandled
 exception thrown during validation: null
 java.lang.NullPointerException
 at
 org.apache.struts.validator.FieldChecks.processFailure(FieldChecks.java:1323)
 at
 org.apache.struts.validator.FieldChecks.validateMask(FieldChecks.java:243)


 Any ideia?

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



Re: Beanutils: Problem with DateConverter

2007-10-08 Thread Niall Pemberton
I replied to this on the dev@ list - please don't cross-post, thanks

http://tinyurl.com/3y2bqm

Niall

On 10/5/07, Chris Helck [EMAIL PROTECTED] wrote:
 Hi,

 I'm trying to use the DateConverter, and it just doesn't seem to work
 (or I don't understand it). Here's my code:

 DateConverter converter = new DateConverter();
 converter.setPattern(MM/dd/yy);
 ConvertUtils.register(converter, java.util.Date.class);

 System.out.println(ConvertUtils.convert(new Date()));

 The output is: Fri Oct 05 12:22:34 EDT 2007
 I expected to see: 10/5/07

 I'm using version 1.8.0-BETA that I rebuilt from the source. I'm aware
 of the bug BEANUTILS-283, but I think I've got the fix.

 Regards,
 Christopher Helck


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



Re: ECCN classification for Apache Commons

2007-09-06 Thread Niall Pemberton
On 8/22/07, Henriques, Tiago (ext) [EMAIL PROTECTED] wrote:
 Hi all,

 We are using Apache Commons in one of our products, and are now in the 
 process of collecting the information needed to export it to other countries.

 In order to do this, can you tell me whether any citizens of the United 
 States of America or people living in the U.S.A. have contributed to the 
 Apache Commons software?

 Can you also tell me what the U.S. Export Control Classification Number 
 (ECCN) for Apache Commons is, and whether a license exception may be used for 
 it?

 In addition to the U.S. ECCN, there is also a German ECCN, which is called 
 the AL Number. Can you tell me what the AL Number is for Apache Commons?

 To better understand the meaning of the U.S. ECCN, please check the following 
 webpage:

 http://www.bis.doc.gov/Licensing/Do_I_NeedAnECCN.html

 Many thanks,

Please see

http://www.apache.org/licenses/exports/

Niall

 Tiago Henriques
 Nokia Siemens Networks

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



[ANNOUNCE] Commons BeanUtils 1.8.0 Beta release

2007-08-05 Thread Niall Pemberton
The Commons team is pleased to announce the release of Commons
BeanUtils 1.8.0 Beta. Commons BeanUtils provides easy-to-use wrappers
around the Reflection and Introspection APIs provided by the Java
language.

BeanUtils 1.8.0 Beta is binary compatible with version 1.7.0 and
contains quite a few bug fixes and enhancements. Since it has been
nearly three years since the last BeanUtils release, it is hoped that
this Beta release will facilitate wider testing to ensure that there
are no major compatibility issues before the final 1.8.0 release.

Commons BeanUtils Website:
http://commons.apache.org/beanutils/

Release notes:
http://commons.apache.org/beanutils/v1.8.0-BETA/RELEASE-NOTES.txt

Download:
http://commons.apache.org/downloads/download_beanutils.cgi

Niall Pemberton,
on behalf of the Commons community

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