geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shawn Jiang <genspr...@gmail.com>
Subject Re: new IBM book: Using WASCE 2.1
Date Fri, 06 Mar 2009 08:43:12 GMT
" there is code that examines the class using reflection and adds all
the operations. "

Can you point out where is the code you mentioned so that we can add
it to the GBean introduction topic ?

On Fri, Mar 6, 2009 at 3:45 PM, David Jencks <david_jencks@yahoo.com> wrote:
>
> On Mar 5, 2009, at 5:59 PM, Shawn Jiang wrote:
>
>> In the traditional GBean, we could use:
>>
>>       infoFactory.addOperation("isStarted", "String");
>>
>> to expose a method of GBean, I'm asking if there is corresponding
>> annotation way to expose a method.
>
> addOperation is not necessary any more because there is code that examines
> the class using reflection and adds all the operations.  This code works
> just as well if you are using annotations :-)
>
> thanks
> david jencks
>
>>
>>
>>
>> On Thu, Mar 5, 2009 at 5:05 PM, David Jencks <david_jencks@yahoo.com>
>> wrote:
>>>
>>> On Mar 5, 2009, at 12:45 AM, Shawn Jiang wrote:
>>>
>>>> Does anyone known how to define the GBean method in annotation way of
>>>> geronimo 2.2 ?
>>>>
>>>> I could not find any info about this in:
>>>> http://cwiki.apache.org/GMOxDEV/gbean-annotations.html
>>>
>>> I'm not sure what you are asking.  You don't need a getGBeanInfo() static
>>> method if you are using annotations.
>>>
>>> The DEV article leaves out:
>>>
>>> you can specify the j2eeType of the gbean in the @GBean annotation and I
>>> think the priority
>>>
>>> the @Persistent and @Reference annotations on setter methods are like
>>> specifying attributes and references in the gbean info builder.
>>>
>>> I've been gradually converting gbeans to use the annotations but have not
>>> yet used the @Persistent and @Reference annotations.
>>>
>>> Some more examples are in the plugin farm clustering code and various
>>> places
>>> in the kernel.
>>>
>>> I guess we should move this page into the 2.2. docs
>>>
>>> thanks
>>> david jencks
>>>
>>>>
>>>>
>>>> On Thu, Mar 5, 2009 at 4:39 PM, Ying Tang <yingtang1983@gmail.com>
>>>> wrote:
>>>>>
>>>>> Hi Juergen,
>>>>>
>>>>> Thanks for your suggestion.  I made some changes  and added a "GBean
>>>>> methods" section:
>>>>>
>>>>>
>>>>>
>>>>> http://cwiki.apache.org/GMOxDOC22/developing-and-deploying-a-geronimo-gbean.html
>>>>>
>>>>> Any comment  is appreciated.
>>>>>
>>>>>
>>>>> Best  Wishes,
>>>>>
>>>>> Sophia
>>>>>
>>>>>
>>>>> 2009/3/5 Juergen Weber <weberjn@gmail.com>
>>>>>>
>>>>>> Hi Sophia,
>>>>>>
>>>>>> I'd suggest you also write (the for me formerly non-obvious points
>>>>>> ;-):
>>>>>>
>>>>>> - a gbean consists of classes in a jar + plan
>>>>>> - you deploy both
>>>>>> - infoFactory.addAttribute("port"  relates to <attribute name="port">
>>>>>> - infoFactory.addOperation names the user methods you can call
>>>>>> - how do you call an operation?
>>>>>>  ->
>>>>>>
>>>>>>
>>>>>>
>>>>>> http://www.nabble.com/How-do-you-access-a-GBean-via-JNDI--td21621410s134.html#a21621410
>>>>>> - how do you put a GBean into JNDI
>>>>>>  ->
>>>>>>
>>>>>>
>>>>>>
>>>>>> http://www.nabble.com/How-do-you-access-a-GBean-via-JNDI--td21621410s134.html#a21621410
>>>>>>
>>>>>> Thanks,
>>>>>> Juergen
>>>>>>
>>>>>>
>>>>>>
>>>>>> Sophia Tang wrote:
>>>>>>>
>>>>>>> Thanks Radim for your suggestion.
>>>>>>>
>>>>>>> A  topic named "Developing and Deploying a Geronimo
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> GBea<http://cwiki.apache.org/confluence/display/GMOxDOC22/Developing+and+Deploying+a+Geronimo+GBean>n
>>>>>>> " has been added to the
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> reference<http://cwiki.apache.org/confluence/display/GMOxDOC22/Reference>section
>>>>>>> in Geronimo 2.2 documentation wiki:
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> http://cwiki.apache.org/confluence/display/GMOxDOC22/Developing+and+Deploying+a+Geronimo+GBean
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Any of your comments is welcome.
>>>>>>>
>>>>>>>
>>>>>>> Best Regards,
>>>>>>>
>>>>>>>
>>>>>>> Ying Tang
>>>>>>
>>>>>>
>>>>>> --
>>>>>> View this message in context:
>>>>>>
>>>>>>
>>>>>> http://www.nabble.com/new-IBM-book%3A-Using-WASCE-2.1-tp22117057s134p22334640.html
>>>>>> Sent from the Apache Geronimo - Users mailing list archive at
>>>>>> Nabble.com.
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Thanks,
>>>> Shawn
>>>
>>>
>>
>>
>>
>> --
>> Shawn
>
>



-- 
Shawn

Mime
View raw message