Basic question concernign EJB class

Hi,
I can not understand why a EJB bean class implements methods defined in the remote interface but not 'implements' that interface itself.
who 'implements' that remote interface.
thanks a lot for your time.
Benjamin

Hi !
The remote inteface inturn has the signatures of all the methods present in the Bean class and not the vice versa and hence u see all the complete bussiness methods in the Bean interface.
Hope i am clear
Regards,
Vin

Similar Messages

  • A basic question regarding derived class

    Hi,
    I am new to Java development, so this might be a very trivial question:
    class Base {
    public void b() {
    System.out.println("Base::b() method invoked");
    class Derived {
    public void d() {
    System.out.println("Derived::d() method invoked");
    class Testing1 {
    public static void main (String[] args) {
    Base val = new Derived();
    obj.d();
    I expected this to compile ( expecting d() to be treated as a virtual function). However I get an error message : "cannot find symbol : symbol d() : location: class Base".
    1. Is it possible to know where I went wrong ?
    2. How can I invoked d() method from val ?
    Regards,
    Anirvan

    two things I see are:
    1. obj isn't defined anywhere
    2. class derived should extend base by: class Derived extends Base
    Gregory

  • Basic question - extending Serializable classes...

    Hi everyone,
    I've got a quick question: if I create a new class that extends a Serializable class, is that class automatically considered to be Serializable, or do I need to explicitly declare that?
    Thank you in advance,
    Pete

    I've got a quick question: if I create a new class that extends a
    Serializable class, is that class automatically considered to be
    Serializable [ ... ]Yes, you're derived class is automagically considered to be Serializable.
    This is what the API docs for the Serializable interface have to say
    about it:
    All subtypes of a serializable class are themselves serializable
    kind regards,
    Jos

  • EJB Facade basic question

    Hi All,
    I have a basic question on EJB Session Facade design pattern.
    What is the extra code we write in normal Session Bean, to make it as Session Facade.
    I never involve in EJB coding, but i know the coding and bit curious to know about it. I see Normal Session Bean coding and also seen Session Facade coding, i dont find any difference in implementation, then y do we call it as a Session Facade design pattern. Are all session beans are by default called Session Facade or do we need to write any extra code in a normal Session bean to make it as SF.
    Requesting to clarify.
    Thanks & Regards,
    Ravi Kumar

    There's a nice explanation on http://java.sun.com/blueprints/patterns/SessionFacade.html.
    The way I read it, my session beans are really session facades already, so why not yours too? However, that page also gives an example of a session bean that wouldn't count as session facade.

  • Fundamental question: Integrating non-EJB classes

    Hi there,
    sorry to ask that, but how can i integrate classes other than EJBs
    into my assembled application ? i use sun's deploytool and their ri
    application server.
    my task is to call a class called J2EEManager at the app server
    startup, which has to initialize some server-wide data. but how do
    i call and integrate this class at deployment level ? in the deploytool
    there isn't such a support. i do also use this class during runtime.
    also i do not see how to integrate my helper classes that are needed
    by the EJBs i developed. again, in deploytool i just can add my EJB's
    but not all the other classes i implemented.
    how does this work ? any hints, links, tutorials ? the examples i've
    seen in books and articles mostly do not cover these things...
    thank you very much. best regards
    rivella50

    When you call the "packager" tool, you can specify any classes you want to include in the package archives. They don't all have to be EJB classes or interfaces. I don't use the deploytool UI, but there should be a way to include extra files into the packages from within the UI mode.
    As for performing extra functionality at server startup, I don't know of any way to do this. However you can create a separate (stand-alone) application that is run on the server machine, just after server startup:
    j2ee &... wait until server is up and running ...
    java J2EEManager <params>Ben

  • A basic question of class

    Hello guys,
    i'm new hand and i got this question but i'm not sur of the answer, any help would be welcome :)
    The correct statement(s) are:
    a: a class is an instance factory
    b: a class is a template for creating an entity
    c: a class is a set of all the instances of a pattern
    d: none of the above

    It is A or B. I'm not sure which one though because it is a strange question.
    A class is a piece of code that creates objects. It's like a factory that produces a certain type of object. It is like the blueprints. Every building has blueprints. When the builders build a building they look at the blueprints to see how it is done. The compile looks at a class as blueprints on how to make something. Think of Terminator 2. One class would create the t1000 robots and another class would create the t2000 robots.
    I hope that helps. I think that A and B could be equally right.

  • Class Loading.Basic Question

    Hi,
    I wrote a small piece of code and it is running fine.
         Enumeration enP = lP.getNameList();
         int i=0;
         while (enP.hasMoreElements()) {
              Object nE = enP.nextElement();
              String nV = nE.toString();
              System.out.println(nV);
    I am in doubt,because as far as I know Enumeration is an interface as sucj an interface it is not supposed to have code. So, my question is which class is in fact been used by the program?

    All you can know it that whatever class it is, it
    implements the Enumeration interface. Well that's not really true. If you're really dying to
    now what type it truly is, just print out its
    class:Enumeration enP = lP.getNameList();
    System.out.println( enP.getClass() );
    That code shows what the class is on a specific version of a specific vendor's library. If you try to rely on that information, don't be surprised if it's a different class in another vendor's library or even the next version of the same vendor's library.
    The truth is you really don't know what class of object a reference will point to when you write the code, at least if the reference type is non-final.

  • Locating EJB classes from JSP

    Hi all,
    I have some JSP that invoke Session Beans. My question is:
    what is the right place to put EJB classes in order to be found by JSP ?
    I have found the following solutions but they both slow down during development
    phase:
    1) Build an EAR and let the JSP reference EJB classes via the Class-Path attribute.
    This is nice but a bit complex: I'd like to use EAR only for shipment phase and
    not for every small change to the Bean.
    2) Let WLS see the classes including them in the classpath at startup. But this
    has the disadvantage that I have to restart WLS every time because - I suppose-
    WLS isn't able to unload classes if I include them in the CLASSPATH
    So what do you suggest me for development phase? is there a faster solution?
    Thanks a lot
    F.Marchioni

    Hi Arjuna,
    put it on the weblogic startup classpath.mmmmm well I think the JSP will not reload the EJB classes when I make a change
    if they are on the classpath...unless I restart the server....I'll try again...I
    hope I'm wrong...
    thanks
    Francesco
    "Arjuna Chala" <[email protected]> wrote:
    for testing
    - put it on the weblogic startup classpath.
    - use the console's hot deploy facility to re-deploy the ejb after changes.
    This works well for me (WLS6.1).
    Reagrds
    Arjuna Chala
    "Marchioni F." <[email protected]> wrote in message
    news:3c5eae94$[email protected]..
    Hi all,
    I have some JSP that invoke Session Beans. My question is:
    what is the right place to put EJB classes in order to be found byJSP ?
    I have found the following solutions but they both slow down duringdevelopment
    phase:
    1) Build an EAR and let the JSP reference EJB classes via the Class-Pathattribute.
    This is nice but a bit complex: I'd like to use EAR only for shipmentphase and
    not for every small change to the Bean.
    2) Let WLS see the classes including them in the classpath at startup.But
    this
    has the disadvantage that I have to restart WLS every time because- I
    suppose-
    WLS isn't able to unload classes if I include them in the CLASSPATH
    So what do you suggest me for development phase? is there a fastersolution?
    Thanks a lot
    F.Marchioni

  • Basic Questions on UITableView

    Hi, I'm trying to learn the iPhone API by creating a simple table application and I have some basic questions. There are stuff in the example code and the docs that seem to contradict, and I'm hoping some people can clarify.
    1) Table View Programming for iPhone OS, it says that UITableView must have a delegate and a source. I take it that in the example code (let's use TableCellSubivews) RootViewController is the source and TableViewCellSubviews is the delegate?
    2) If so, why does TableViewCellSubviews adopt the UIApplicationDelegate protocol and not UITableViewDelegate? In fact, I don't think any of the classes in the example code adopt UITableViewDelegate.
    3) In the UITableViewDelegate reference, it names didSelectRowAtIndexPath as a method. In the example code, why is in the didSelectRowAtIndexPath a method in the RootViewController, and not the delegate itself?
    Thanks for any explanations that anyone can give to help a noob!

    {quote}
    1) Table View Programming for iPhone OS, it says that UITableView must have a delegate and a source. I take it that in the example code (let's use TableCellSubivews) RootViewController is the source and TableViewCellSubviews is the delegate?
    {quote}
    There are 3 things that need to be done when setting up a tableview:
    1- the tableview controller itself, which determines how the tableview is set up, decides on the view, etc..
    2- the data source: the controller in 1) above needs to ask someone "give me the cell with the data for row #x. That's the job of the data source
    3- The delegate: some things for the table view need visible stuff such as the height of a row, whether a row should have a checkmark, etc... That's the job of the delegate.
    Now what often happens is that people do not specify a data source nor a delegate. What this means is that the controller performs all 3 jobs. Again, if the controller does not specify its delegate (or no class registers as its delegate), then the controller acts as its own delegate. (that answers your second question)
    {quote}
    3) In the UITableViewDelegate reference, it names didSelectRowAtIndexPath as a method. In the example code, why is in the didSelectRowAtIndexPath a method in the RootViewController, and not the delegate itself?
    {quote}
    That's a tricky question.
    The thing is that both the data source AND the delegate adopt a method called didSelectRowAtIndexPath. But they're for very different purposes. For the delegate, it's simply a notification by the controller that "hey, this row was selected, you may want to do something with it", i.e. change the color of the font, add a checkmark, etc...
    For the data source, it's much more important (and required!): the controller is saying "hey, someone requested row #x. Please give it to me!" This includes getting all the data and setting up the whole row, then returning it to the controller.
    Hope this helps clear things up.

  • Basic questions of structure Alchmy inside the AVM ans corePlayer ? Help!

    Hello community:)
    Flash Player 10 has been amended in order to run the new code from the compilation Alchemy! Is this correct?
    The new ABC Alchemy is for new features such as memory pointer, asynchronous functions? is that correct? and what else?
    This amendment consists of a small AVM separated from the Tamarin ? where everything is in Tamarin?
    The memory allocated to code from Alchemy is separated from the memory area allocated to the AVM and PlayerCore? it is like that?
    The CorePlayer flashRuntime and had to be changed?
    The ABC from Alchemy is intended only as to the AVM? or also to CorePlayer?
    Alchemy can access the BIOS? especially for 33h the mouse? if not, is it possible to control the mouse in one way or another with Alchemy?
    Immagine it would create a code C to produce sound from a bytesArray to replaceSampleData AS3 class, it's possible? If not, why? a restriction of the sandbox?
    Can be added directly to the assembler code using Alchemy? or it's prohibited because of the respect of cross platefrom?
    Thank you for maximum responses! although one can easily imagine some answers, I have confirmation:)
    Too many people claim things on forums, affirmative behave as if it was the system programmers themselves FlashPlayer! Outside, people sometimes give wrong answers! Two days ago, I had a guy who claimed that the AVM does not compile ABC! The ABC was executed directly .  It's sad and a shame to read such things. He obviously did not read and do not know the JIT
    This post is aimed at people on what they say and who were able to verify the information. Alchemy or programmers themselves.
    Thank you all!

    In order to understand things and not waste our time trying to code without knowing ifthey are not working because of am or even if it is because it is not impossible or not the player, I'm posted this on the forum Player. But my post is not answered .. Adobe programmers never come on this forum? Nobodyknows exactly how it works?
    Hello everyone
    I have some basic questions about the Flash player and  AVM2..
    I made this little flow chart for Player 9 and above >
    Can  anyone tell me if it is consistent and fair to me or to report a possible error?
    AVM2 the only accessing the CPU and Ram? and in no event in the device or OS API, right?
    The AVM2 in our current players is always a Tamarin?
    The next step is to replace the JIT by the nanoJIT spiderMonckey?
    The byteCode from Alchemy is well executed in the AVM and not elsewhere?
    The memory area codes assigned to Alchemy is the same as that of the AVM or is it different andseparate?
    Thank  you for your answers.
    Gordially,  Alain.

  • OC4J 9.0.4 stand alone - basic questions

    Hi,
    I'm upgrading my web applications from OC4J (1.0.2.2) to OC4J 9.0.4.
    I have a few basic questions. Since I asked these as part of another thread and didn't get a response, I thought starting a new thread might help...
    1. Does the JSP compiler in OC4J 9.0.4 (JSP container) work with the JDK version set in the path ? (I'm not using OJSP).
    2. I read that OC4J 9.0.4 is J2EE 1.3 compliant. With OC4J 1.0.2.2 , I used the j2ee.jar file (that was bundled with J2SDKEE 1.3) to compile my Servlets/Struts code. I copied it into the OC4J_HOME directory and set the Classpath to it, to build my classes.
    With 9.0.4, can I still use this j2ee.jar file or do I need to use the jar files (Servlet.jar) in the OC4J_HOME/lib directory?
    3. Could somebody throw some light on why some jar files are placed in OC4J_HOME while others are in the OC4J_HOME/lib directory ? What is the difference?
    Any help/suggestions will be greatly appreciated.
    Thanks,
    Shyam

    Hi, shyam:
    It is nice to raise different questions in different threads.
    1. Does the JSP compiler in OC4J 9.0.4 (JSP container) work with the JDK version set
    in the path ? (I'm not using OJSP).I believe you are referring to the runtime JSP engine, which compiles your JSP when you first access it. The answer is yes.
    To see the compilation setting when oracle jsp engine is compiling jsp files, start oc4j with the debug flag:
      java -Dbuild.debug=true -jar oc4j.jar
    2. I read that OC4J 9.0.4 is J2EE 1.3 compliant. With OC4J 1.0.2.2 , I used the
    j2ee.jar file (that was bundled with J2SDKEE 1.3) to compile my Servlets/Struts code.
    I copied it into the OC4J_HOME directory and set the Classpath to it, to build my
    classes. With 9.0.4, can I still use this j2ee.jar file or do I need to use the jar files
    (Servlet.jar) in the OC4J_HOME/lib directory?Not sure what to say about j2ee.jar of j2SDKEE1.3 since I have never used it. For Servlet code, they are pure java code as long as you use the right libraries. Use the one in OC4J_HOME/lib if possible, although it probably does not matter much. For JSP file, there is no problem of compilation if you do not want to precompile them. All you need is packaging them and deploying them.
    3. Could somebody throw some light on why some jar files are placed in OC4J_HOME
    while others are in the OC4J_HOME/lib directory ? What is the difference?The executable jars are in OC4J_HOME directory. Besides that, I do not see see much difference.

  • Basic question reg. distributed installatio

    Hi everybody,
              i have a very basic question, for which i wasn`t able to find a simple
              answer/solution.
              I am planning to set up Bea in a distributed environment. the idea is
              to have a physical machine for the presentation, meaning
              webserver/jsp/servlets in the dmz1 and a machine with the application
              server holding ejbs in a different dmz.
              This results in an architecture where the presentation layer only can
              be contacted via http/https by the users and the logic layer
              communicates with the pres. layer via RMI/T3.
              Is there any documentation on such a setup ? any hints ?
              Thanks in advance, i'll keep on searching the dox.
              Berthold Krumeich
              

    [att1.html]
              

  • Question on EJB, JNDI and client jars

    Hi,
    This is a very fundamental question on EJBs and their clients - what
    all should go into the client jar of an ejb?
    I know for sure that just the remote and home interface classes of the
    ejb are sufficient on the client's classpath to work with an EJB on a
    totally different server, but I dont understand the logic behind it.
    If the client has to pass its object parameters over the network to
    the server where the ejb bean is located, should the container
    generated stub not be present on the client's classpath? After the
    client does the JNDI lookup of the ejb home on the server, how does it
    serialize and pass the parameters over the network if the container
    generated stub is not present?
    Any help would be greatly appreciated. Pointers to material on the
    internet which explain this/related things in detail would be a great
    help.
    Thank you,
    Anoushka

    "Anoushka" <[email protected]> writes:
    I know for sure that just the remote and home interface classes of the
    ejb are sufficient on the client's classpath to work with an EJB on a
    totally different server, but I dont understand the logic behind it.
    If the client has to pass its object parameters over the network to
    the server where the ejb bean is located, should the container
    generated stub not be present on the client's classpath? After the
    client does the JNDI lookup of the ejb home on the server, how does it
    serialize and pass the parameters over the network if the container
    generated stub is not present?Most protocols (IIOP, T3, JRMP) provide a slot for encoding a codebase
    in RMI requests. The codebase is usually an http URL that specifies
    where to get classes that are not currently available to the
    client. This URL is used to construct a java.net.URLClassLoader which
    then downloads classes on demand. These classes can include stubs,
    object arguments - pretty much anything you like. There are certain
    security restrictions on the URLClassLoader which is why you sometimes
    have to specifiy a security manager in a client. T3 will for
    preference generate stubs in the client rather than download them,
    however this is not allowed in an applet - and so in this case T3 will
    also download stubs from the server.
    The net of this is that you don't have to put very much at all in a
    client jar UNLESS you can't use the URLClassLoader. In that instance
    you have to put EVERYTHING you need in the client jar.
    HTH
    andy

  • Hi questions on ejb??????

    hi everybody.... can you give my questions answers.........................
    if we write abstract class in case of home and object interface? and all the methods needed put in the Abstract class is the ejb code is working..... if yes...so why.... if no then why........

    Chunbo Huang <[email protected]> wrote:
    Hi,
    I have the following two questions on EJB while I am working a project based
    on EJB:
    (1) What is the guideline to implement a cluster-wise exclusive on EJB? In
    another word, I want to have only one EJB instance for a DB record to be
    created among all the cluster nodes. As far as I know, the EXCLUSIVE
    concurrent control setting in EJB deployment descriptor only works in the
    single node. Is that right?Yes.
    (2) Giving the RObean cachel invalidation process, if I use cacheHome
    interface to invaliate the corresponding RO beans, does this gurantee the
    ROBean will not read any out-of-date data? Or there are still a small window
    the ROBean may have the old data?Yes, there is a small window when RO bean can have the old data. If you invalidate
    beans manually (using CachingHome) make sure you do this after update transaction
    commits - that way RO bean will not read old data.
    Thanks!
    --chunbo--
    Dimitri

  • JDeveloper/OAS/Oracle - Basic Question

    Hi,
    I have a very basic question. I want to write a simple application using JDeveloper 3.0, OAS 4.0.8.0 and Oracle 8i as the database. The functionality of the application will be to simply display all the rows from a particular Oracle table on a front-end screen.
    Can anyone suggest which would be the best architecture to adopt. Should I use EJBs, or applets or .
    There are no examples (samples) provided with the documentation that illustrate simple applications like the one I am trying to build.
    It will be great is someone could illustrate (step-by-step) what I should use to paint my front-end screen, what I should use to write my SQL (to retrieve rows from the Oracle table) and how I should deploy all of this on OAS.
    Thanks in advance.
    null

    I guess my question was not framed correctly. I am new to JDeveloper and was trying to learn how to develop applications using the tool. I am also new to Internet programming in general so please bear with me. Coming from a old Client/Server school, I thought I would start learning JDeveloper by creating a "Client" using the many features of JDeveloper and then call a "Server" to do the database access. Now my question was the process to go about doing this. You have asked me whether I want to create an application or an applet. Well, the answer is that I frankly dont know. I want to be able to design (paint) a HTML page on which I want to be able to display rows from a Oracle table. Once I have managed to do this simple application I will start putting more complex functionality into that application to learn advanced features. Hope that helps.

Maybe you are looking for

  • Use Mini DisplayPort to DVI adapter to connect Mac Mini to Cinema Display?

    Hi I have a new-to-me current model Mac Mini and want to use it with my 20" Cinema Display (model A1081). The Mac Mini instructions say to use the HDMI port on the Mac Mini with a DVI>HDMI adapter cable. I seem to have only a DVI>Mini DisplayPort ada

  • Problem with Oracle deadlocks

    We are having severe problems with deadlocks in Oracle. We have a web-based student online course registration system that gets hit hard at the precise minute registration starts, then proceeds to generate between 100-200 trace files within 10 minute

  • Socket and 0x00 byte...

    I've been working on some code to load data using the new flash.net.Socket class, but I seem to have a problem with files being sliced at '0x00' bytes... For example, should I try to send (download) AA BB CC DD EE FF 00 11 22, and then query the byte

  • Question on PMCO Table

    Hi All,          I have some doubts related to PMCO Table .. I have an order for which confirmation been done as on todays date , 26th April 2011 ..but in PMCO it is reflecting in WRT05 .. here i believe it should reflect in WRT03 for April ...  but

  • HT5467 how do you change back to the south african store from the american store on your settings??

    how do you change back to the south african store from the american store on your settings??