Return-Path: Delivered-To: apmail-ibatis-user-java-archive@www.apache.org Received: (qmail 73074 invoked from network); 10 Oct 2006 22:57:35 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 10 Oct 2006 22:57:35 -0000 Received: (qmail 26508 invoked by uid 500); 10 Oct 2006 22:57:33 -0000 Delivered-To: apmail-ibatis-user-java-archive@ibatis.apache.org Received: (qmail 26334 invoked by uid 500); 10 Oct 2006 22:57:32 -0000 Mailing-List: contact user-java-help@ibatis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user-java@ibatis.apache.org Delivered-To: mailing list user-java@ibatis.apache.org Received: (qmail 26316 invoked by uid 99); 10 Oct 2006 22:57:32 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 10 Oct 2006 15:57:32 -0700 X-ASF-Spam-Status: No, hits=0.5 required=10.0 tests=DNS_FROM_RFC_ABUSE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: domain of larry.meadors@gmail.com designates 66.249.82.227 as permitted sender) Received: from [66.249.82.227] (HELO wx-out-0506.google.com) (66.249.82.227) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 10 Oct 2006 15:57:31 -0700 Received: by wx-out-0506.google.com with SMTP id h30so26751wxd for ; Tue, 10 Oct 2006 15:57:11 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:sender:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth; b=ugYvspWnNpUtYzUOxAW+ScfixCjbgS3Ckqvd9DWK0MYiS8bKoARkbdGzAJ1qiXuz7APuh1AqLdaSVBsajCRzfQWpTh1n24UM0uI8mptwLL9LWrX6r9AAOFR538C8igbGDcuCfhnQ3+MJ1hPUNuCkEBRzZUupCjKB7harr/QA7Eg= Received: by 10.90.119.15 with SMTP id r15mr12125agc; Tue, 10 Oct 2006 15:57:10 -0700 (PDT) Received: by 10.90.87.17 with HTTP; Tue, 10 Oct 2006 15:57:10 -0700 (PDT) Message-ID: Date: Tue, 10 Oct 2006 16:57:10 -0600 From: "Larry Meadors" Reply-To: lmeadors@apache.org Sender: larry.meadors@gmail.com To: user-java@ibatis.apache.org Subject: Re: Enum typeHandlerCallback In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: X-Google-Sender-Auth: 7da0d4324837a487 X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N An inner enum class? Hmm, should it be: javaType="com.sybase.cosmos.domain.DocumentStore$State" Larry On 10/10/06, Christopher.Mathrusse@sybase.com wrote: > > > I'm attempting to implement a TypeHandlerCallback to handle an Enum. The > Enum is declared within a class but I can't seem to figure out how to do > this correctly. I keep getting an exception thrown at startup because iBatis > cannot seem to load the enum. In the Resources class, the method > classForName(String) keeps throwing an exception based upon the javaType > that I have specified in my config file. > > SqlMapConfig Type Handler declaration: > > > javaType="com.sybase.cosmos.domain.DocumentStore.State" > callback="com.sybase.cosmos.dao.impl.ibatis.extentions.DocStoreStateTypeHandlerCallback" > /> > > Enum defined in java class: > > > public class DocumentStore extends DomainObject { > > public static enum State { INITIALIZED, PROCESSING, COMPLETE, ERROR } > > > The following in Resources.classForName(String), which is using the class > loader, cannot locate the enum that I have specified. So how can I tell > iBatis to use my TypeHandlerCallback for this enum? > > > > Thanks.... > > Chris Mathrusse > christopher.mathrusse@sybase.com > (925) 236-5553 >