Model class for auction

Dear experts , I have a requirement to send a mail to the manager of buyerwhen buyer click's on save button while creating auction , I am searching for the method which gets call on clicking on save .
I am new to SRM , dont know how to search out for classes and methods in SRM

solved by my self ,
it is /SAPSRM/IF_PDO_BO_AUC~ACTION_HOLD

Similar Messages

  • How to set the Model Class for a newly created Model Node ?

    Hello All,
      I am trying to map a Model node from SourceA to DestinationB.
      To do so, I created a model node for Destination B in the interface controller (set the isInputElement to true). However why I try to map the node, I get an error saying that "Both context nodes have to be bound to a model class". Upon a closer look, I realised that the model node that I created in DestinationB has no entries under the properties.
      Does anyone knows/advise how I can add the model class entry to the model node that I have created as I am not able to do so. Or otherwise, is there a way to map a model node to another model node across different components ? Thank you very much.
    from
    Kwok Wei
    from
    Kwok Wei

    Hello Pascal
      The instructioons that you gave are for mapping the model between the view controller and the component controller within the same component is that right ?
      I am tryng to map a model node in the component controller of SourceA to another model node that belongs to another Component. I do believe that in this case I will need to create a model node in the interface controller of DestinationB and map that to the component controller of SourceA. However, by creating my own model node, how do I change the property modelClass in the context ?
      Thanks !
    from
    Kwok Wei

  • How to implement custom Model Class in Oracle ADF?

    I am using Oracle ADF for one of my project and i am using Query component of ADF. For given tables the query component creates view objects and maps the relations. ADF uses its own custom model class for this component and it should understand the DB tables. But for my project i have no access to database. All i can do is pass a string or object/query to the existing (custom) Java class/object, and this model class formulates query and queries the database and returns the value to my Java class. I have to display these results using ADF to the front end. Is There a way to achieve this? Can i replace/override the existing Model class of ADF. If so how?
    Thanks in advance for your help.

    Hi, there:
    Best thing to do is to start with the default login.html page, and then modify it. The login screen is fairly complex and it's easy to just miss a JS function you need to call. To get to default page, you would need to do one deploy (to simulator or whatever), and then look for login.html page in the temporary Xcode or Android project generated from the deployment. It should be under the "deploy" directory in your JDev workspace.
    You can also see all the framework JS files and CSS files that way as well.
    We have had customers implementing custom login screen so we know it can work, but they all had to start with the default login screen and then modify it.
    Thanks,
    Joe Huang

  • Development class for program RFIDESM340 ( Model 340 )

    Hello everyone ,
    I have implemented all the notes pertaining to Model 340 .
    I have a doubt regarding the development class for report  RFIDESM340 .
    In the system the development class for report  RFIDESM340   is ' BUPA_TAX ' .
    I want to confirm if this is the right one or should we change the development class to ' ID-FI-ES '.
    Thanks ,
    Lalitha Iyer .

    Hola Eduardo!
    La clave de operacion ya está parametrizada en la tabla ES340_OPRKEY.Este no es el problema.
    Lo que necesitamos es poder incluir dos Tipos de libros .
    El estándar de sap solo saca dos tipos de libros
    Libro de facturas expedidas.
    Libro de facturas recibidas.
    que están identificados en el reporte con las claves de tipo de libro E y R.
    Necesitamos que el reporte obtenga tambien los libros de
    Libro de determinadas operaciones intracomunitarias.
    Libro de bienes de inversión.
    Cuyas claves de tipo de libro son: U y S
    Estas claves No tienen nada que ver con la clave de operacion.
    Este es un requerimiento a la hora de presentar el reporte y SAP no  aporta solucion.

  • Idea for Chat Socket (what�s the best maner to send model class?)

    I Hava a server/client chat socket. Multitreading to recieve multi-conections. I have a model style class, like a Message, that you send this class for exemplo from Client to Server.
    Message Class
    * name as String
    * msg as String
    I used ObjectStreams like ObjectOuputStream and ObjectInputStream to send and receive this object liked. But I need to serialize this model class to send it. Is the best maner to use Object Strams, or have another easy solution to send this class model??
    I demand ideas!
    Thanks all!

    If you are communicating serializable objects between Java clients then sure, ObjectOutputStream & ObjectInputStream are a pretty easy way of doing that.
    One downside is that OOS & OIS are difficult to use in non-Java programs. If you want interoperability with other languages you might communicate using e.g. CORBA, XML, or a protocol of your own design. Those require a bit more work and learning though.

  • Macbook Pro : Which model best for a student? Thanks.

    Hi, I'm currently pursuing 2nd year of pharmacy programe, and I'll be moving abroad to finish another 2 more years of my studies. And before that, I want to replace my current Macbook White Unibody Late 2009 model. I know it still works well, at least up to my needs. But I wish to get a much more sturdy and of course, better build quality, not to mention that I have a few cracks for my White. So I am looking at the current Macbook Pro 13 inch, knowing that the higher end 13 inch doesn't really worth for the bucks. I've been comparing it with the refurbished Early 2011 15 inch Macbook Pro, can't cough that much money for a brand new one, hope you can bear with it. I know the new Macbooks are coming, but if I were to get the 15 inch model, I probably won't be getting the new Macbook, rather than getting a refurbished late 2011 model, saving for that I'm just a regular user, lots of works, journals and stuff to work with, so I really like a bigger display than my current 13 inch. Apart from that, I have been thinking to get an external monitor display when I move abroad later on, but looking at the matter that I have pack and deliver that monitor back to my own country after graduating, I don't feel like getting a monitor then, kind of troublesome for me. So I hope to seek for some professional advice from fellow Mac users. Any advice is most welcome and God bless you all. Thank you for your help. I really do appreciate it Hope you have  nice day ahead.
    Edit : I have an iPad 3, so I would probably bringing that to class more often rather than any laptop, on frequent use. Knowing that my accommodation is 30minutes away from my campus.. Anyway, thanks for your help.

    Are you still looking for an early 2011 15 inch macbook pro? i currently have one that I'm hoping to sell in the next month or two. It's less than a year old and is like new. If you're interested at all in video editing and/or 3d rendering, some hardcore gaming, this laptop can handle them, thoughthe GPU is somewhat lackluster. But for everyday tasks, light video editing, HD movies, this should be able to last a long time. I got it stock, except I swapped the harddrive for a Seagate 500 gb Momentus XT Hybrid Hard Drive. I also got a protective snap-on cover and keyboard protector. If you're interested at all though, contact me.

  • Error while creating model classes, operation aborted in NWDS

    Hi All,
    When i select Adaptive rfc 2 model  and then search for the RFC,  when i select RFC and click on next i get an error while importing :
    Error while creating model classes, operation aborted.
    It is working fine in visual composer and i have activated function module, RFC but getting same error. It is also working in web service navigator also.
    Can any one help me out??
    Regards,
    Pradeep kumar
    Edited by: pradeep_546 on Feb 17, 2011 9:35 PM
    Edited by: pradeep_546 on Feb 17, 2011 9:36 PM
    Edited by: pradeep_546 on Feb 17, 2011 9:37 PM

    Hai guys thanks for reply
    Tushar,
    I am using NWDS 7.2, ce7.2 server, ECC 6.0.
    Amit,
    I have tested the JCO destinations they are working fine and i created a new pair of JCO destinations but unable to import the Adaptive RFC2 Model gives same error but Adaptive webservices are working fine in my NWDS7.2
    Deepak,
    I am unable to create model in other projects also.
    I have sufficient amount of memory in my drive.
    I have imported the DC to other NWDS but it gives same error.
    Thanks for all,
    Regards,
    Pradeep Kumar G
    Edited by: pradeep_546 on Feb 18, 2011 3:05 PM

  • Error while mapping a Java class for a Search Dialog Box component

    Hi,
    Scenario : There is PAR which I have developed for the sorting options for a Search Component set to be used in Km Search Iview.
                   I have copied this PAR from a similiar search functionality and customised the same.
    Problem: When I deploy the PAR and then map this class for the sort options while creating a New Search Dialog box :
    I get the following "Class not found error" ... Please can you let me know what could be the problem.
    Any help would be appreciated here as I have tried all the possibilities to solve the problem.
    Regards,
    Vaishali.

    I modified the xml file as described in the forum.But the error persists.
    One interesting thing is:
    When I create model after restarting the NDS,I get the following error:
    org.eclipse.swt.SWTException: Failed to execute runnable <i>(java.lang.ExceptionInInitializerError: JCO.classInitialize(): Could not load middleware layer 'com.sap.mw.jco.rfc.MiddlewareRFC'
    JCO.nativeInit(): Could not initialize dynamic link library librfc. Found version "620.0.1237" but required at least version "620.0.1374".)</i>
    I get the NoClassDef found error next time onwards,
    Where do I get the 620.0.1374 version of librfc?
    thanx.
    Bhupesh

  • Flex with any ORM - Writing Model classes and action scripts redundant?

    Hi,
    I am using Hibernate with Flex. I have all my model classes
    as POJOs. Now if i have to access these POJOs directly from flex, I
    need to write action script reference classes for all my POJO model
    classes. Since mapping POJOs with action script reference classes
    is so mechanical, i am wondering if there is any tool to read all
    the properties from the POJO's and convert them to action script
    reference classes automatically. Is there any way that this can be
    automated?
    Thanks in advance.
    Chandu.

    If you use Granite Data Services, there's something called
    "gas3" (I think is the name). You may be able to use it even if you
    don't use Granite.
    I didn't care for learning how to use it (plus it uses
    Groovy, more needless stuff to learn I guess), so I can't say how
    well it works. I just wanted a simple custom ant task that
    generates ActionScript classes for my Java classes. So I ended up
    making my own. It's definitely not trivial but it's not that hard
    if you're very good with Java and reflection.

  • Can't fill ByteArray in EJB-Method with generated Model-Class from WD-Model

    Hello everybody,
    i try to call an ejb-method with data from an FileUpload-UI-Element in WD. The EJB-Method is receiving the byte-data to create a document in KM via a Web-Service.
    The ebj-methid has the following signature:
    public FObject putFileDataSimple (byte [] btContent, String fullFileName, String username, String password)
    After importing the Model and creating a context node i have the following structure:
    Request_X_putFileDataSimple
    +---btContent (Node)
          +-- item
    + fullFileName
    + username
    + password
    btContent is of the generated Type Byte_Item, which is itself a generated Model-Class of modelClassType ARRAY
    item is of Type byte
    But i simply have problems to fill the context node (or the binded model-object). i tried different ways and looked at thread [https://www.sdn.sap.com/irj/scn/thread?messageID=1954223] but i cant get it work.
    So my Method in WD looks like this to fill the structure and start the ejb-method:
    public boolean putKMDataSimple( com.sap.tc.webdynpro.services.sal.datatransport.api.IWDResource fin )  {
    try
      wdContext.currentRequest_X_putFileDataSimpleElement().setFullFileName("abc");
      wdContext.currentRequest_X_putFileDataSimpleElement().setUsername("def");
      wdContext.currentRequest_X_putFileDataSimpleElement().setPassword("xxx");
      byte[] buffer = new byte[1];
      InputStream in = fin.read(false);
      int i = 1;
      int j = 0;
      while (i!=-1)
         i = in.read(buffer);
         if (i!=-1)
           Byte_Item bi = new Byte_Item(mAlf);     // mAlf ist global defined Model-Class-Instance
           bi.setItem(buffer[0]);
            wdContext.currentRequest_X_putFileDataSimpleElement().modelObject().addBtContent(bi);
      wdContext.currentRequest_X_putFileDataSimpleElement().modelObject().execute();
    Doing this results in Error-Messages like:
    Model-Object is not a complex type for every byte added this way.
    And finally an IllegalArgumentException at java.lang.reflect.Array.set(Native Method)
    The second way i tried is:
    public boolean putKMDataSimple( com.sap.tc.webdynpro.services.sal.datatransport.api.IWDResource fin )  {
    try
      wdContext.currentRequest_X_putFileDataSimpleElement().setFullFileName("abc");
      wdContext.currentRequest_X_putFileDataSimpleElement().setUsername("def");
      wdContext.currentRequest_X_putFileDataSimpleElement().setPassword("xxx");
      byte[] buffer = new byte[1];
      ArrayList<Byte> btlist = new ArrayList<Byte>();
      InputStream in = fin.read(false);
      int i = 1;
      int j = 0;
      while (i!=-1)
         i = in.read(buffer);
         if (i!=-1)
              btList.add(buffer[0]);
      wdContext.currentRequest_X_putFileDataSimpleElement().modelObject().setBtContent(btList);
      wdContext.currentRequest_X_putFileDataSimpleElement().modelObject().execute();
    Trying so results in:
    java.lang.ClassCastException: class java.lang.Byte:null incompatible with interface com.sap.tc.cmi.model.ICMIModelClass:library:com.sap.tc.cmi(at-sign)[email protected]@alive
    whenn calling the setBtContent Method
    I don't what to do now to fill the context/model-object the right way.
    Any helpfull hints are very welcome
    Edited by: Matthias Hayk on Dec 1, 2008 5:51 PM
    Edited by: Matthias Hayk on Dec 2, 2008 10:56 AM

    Ok Vesselin and thanx for your idea,
    so i adapted the source in the way you told like the following:
                     ArrayList<Byte_Item> btlist = new ArrayList<Byte_Item>();
                     byte[] buffer = new byte[1];
                     InputStream in = fin.read(false);
                     int i = 1;
                     int j = 0;
                     while (i!=-1)
                          i = in.read(buffer);
                          if (i!=-1)
                               // Byte gelesen
                               Byte_Item bi = new Byte_Item(mAlf);
                               bi.setItem(buffer[0]);
                               btlist.add(bi);
                               j++;
                     wdContext.currentRequest_X_putFileDataSimpleElement().modelObject().setBtContent(btlist);     
                     wdContext.currentRequest_X_putFileDataSimpleElement().modelObject().execute();
    This results also in the following Exception when exceuting the WS-proxy:
    execute
    [EXCEPTION]
    java.lang.IllegalArgumentException
    at java.lang.reflect.Array.set(Native Method)
    at com.sap.tc.webdynpro.model.ejb.model.EJBGenericModelClassExecutable.getInputParameters(EJBGenericModelClassExecutable.java:215)
    at com.sap.tc.webdynpro.model.ejb.model.EJBGenericModelClassExecutable.execute(EJBGenericModelClassExecutable.java:112)

  • Unable to compile class for JSP in tomcat

    Hi
    I developed an application. it works Ok in embedded OC4J server. But I get the following error when I deployed to tomcat server :
    org.apache.jasper.JasperException: Unable to compile class for JSP
         org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:510)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:375)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)
         com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:322)
         com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
         oracle.adfinternal.view.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:157)
         com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
         com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
         com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
         javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
         oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._invokeDoFilter(AdfFacesFilterImpl.java:367)
         oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._doFilterImpl(AdfFacesFilterImpl.java:336)
         oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl.doFilter(AdfFacesFilterImpl.java:196)
         oracle.adf.view.faces.webapp.AdfFacesFilter.doFilter(AdfFacesFilter.java:87)
         oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:332)
         org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)
    I followed the steps of deploying exactly as Oracle developer guide and I don't know what is the reason of this error
    please how can I solve this problem

    Hi
    16-Jan-2007 04:09:17 org.apache.catalina.core.StandardWrapperValve invoke
    SEVERE: Servlet.service() for servlet Faces Servlet threw exception
    Compile failed; see the compiler error output for details.
    at org.apache.tools.ant.taskdefs.Javac.compile(Javac.java:933)
    at org.apache.tools.ant.taskdefs.Javac.execute(Javac.java:757)
    at org.apache.jasper.compiler.AntCompiler.generateClass(AntCompiler.java:219)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:297)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
    at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:303)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:672)
    at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:463)
    at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:398)
    at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301)
    at com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:322)
    at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
    at oracle.adfinternal.view.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:157)
    at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
    at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
    at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._invokeDoFilter(AdfFacesFilterImpl.java:367)
    at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._doFilterImpl(AdfFacesFilterImpl.java:336)
    at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl.doFilter(AdfFacesFilterImpl.java:196)
    at oracle.adf.view.faces.webapp.AdfFacesFilter.doFilter(AdfFacesFilter.java:87)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:332)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
    at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
    at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
    at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
    at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
    at java.lang.Thread.run(Thread.java:595)

  • MVC Problem with getter method of table attribute in model class

    Hi,
    I am on 620 SP34. I am writing a bsp application with mvc. One of the model classes has an attribute of type table. I use this attribute in a htmlb-tableview and '//MODEL/ZMY_TAB' for data binding. If I try to activate a getter method for this attribute, the application dumps with exception <i>BSP exception: Structure component with name "ZMY_TAB" does not exist</i>. I find the SAP source, that raising this exception (see below). The source code looks like: <i>"I don't support getter methods for tables in attribute path"</i>! The setter method works fine, so I am at a loss. Has anyone of you wrote a getter method for an table attribute in bsp-mvc? Have I to consider anything special?
    Thanks,
    Carsten
    Main Program CL_BSP_MODEL==================CP
    Source code of CL_BSP_MODEL==================CM00Z
    METHOD IF_BSP_MODEL_BINDING~GET_ATTRIBUTE_DATA_REF
           * check if attribute exists for binding!                                   
             if exists_attribute( l_name ) is initial.                                
               return.                                                                
             endif.                                                                               
    * setter or getter defined? Not supported for DATA REF requests            
             if get_getter( attribute_name = l_name ) is not initial.                 
               raise exception type cx_bsp_inv_component                              
                 exporting name = l_name.                                             
             endif.                                                   

    You have two options:
    1. Make your attributes public. It should work fine.
    2. If you need to process the attribute values before it is used, you can make the attribute private but will need three methods
    GET_T_ZMY_TAB that returns the table
    SET_T_ZMY_TAB that sets the values
    GET_M_T_ZMY_TAB that returns DDIC information about the attribute. The same holds good for structures(Change to GET_S_ and GET_M_S_ ) and simple attributes(Change to GET_ and GET_M_).
    The set and get methods are kind of documented at http://help.sap.com/saphelp_nw04/helpdata/en/fb/fbb84c20df274aa52a0b0833769057/content.htm but there is no mention of the GET_M_ methods. I could not find one single document on the Model part MVC.
    Once I added the GET_M_XYZ methods to my attributes, my BSPs started to work fine.
    Cheers
    Sreekanth

  • Provide a class for authoring a simple letter.

    Provide a class for authoring a simple letter. In the constructor, supply the names of the sender and the recipient: public Letter(String from, String to) Supply a method public void addLine(String line) to add a line of text to the body of the letter. Supply a method public String getText() that returns the entire text of the letter. The text has the form:
    Dear recipient name :
    blank line
    first line of the body
    second line of the body
    last line of the body
    blank line
    Sincerely,
    blank line
    sender name
    Also supply a program LetterPrinter that prints this letter:
    Dear John:
    I am sorry we must part.
    I wish you all the best.
    Sincerely,
    Mary
    Construct an object of the Letter class and call addLine twice.
    Hints: (1) Use the concat method to form a longer string from two shorter strings. (2) The special string "\n" represents a new line. For example, the statement
    body = body.concat("Sincerely,").concat("\n");
    adds a line containing the string "Sincerely," to the body.
    Complete the following class in your solution:
    This class models a simple letter.
    public class Letter
    Constructs a letter with a given sender and recipient.
    @param from the sender
    @param to the recipient
    public Letter(String from, String to)
    Adds a line to the body of this letter.
    public void addLine(String line)
    Gets the text of this letter.
    public String getText()
    private String sender;
    private String recipient;
    private String body;
    }

    I've answered the question and I've gotten the right answer. However, when I uploaded in our online homewok (which calls WileyPlus, "Launch LabRat") it gives me and error because it's a machine not a human to correct my answer. So, I thought people here could help me to come up with some new codes that would actually work in the "Launch LabRat".
    Here's how I answered the problem (it works perfectly in the BlueJ, but "LabRat" fails the solution):
    This class models a simple letter.
    public class Letter
    Constructs a letter with a given sender and recipient.
    @param from the sender
    @param to the recipient
    public Letter(String from, String to)
    sender = from;
    recipient = to;
    text = text.concat("Dear ").concat( recipient).concat(":").concat("\n").concat("\n");
    Adds a line to the body of this letter.
    public void addLine(String line)
    text = text.concat(line).concat("\n");
    Gets the text of this letter.
    public String getText()
    text = text.concat("\n").concat("Sincerely, ").concat("\n").concat("\n").concat(sender);
    return text;
    private String sender;
    private String text = "";
    private String recipient;
    This is the Tester
    public class LetterTester
    public static void main(String[] args)
    Letter departure = new Letter("Mary", "John");
    departure.addLine("I am sorry we must part.");
    departure.addLine("I wish you all the best.");
    String departureLetter = departure.getText();
    System.out.println(departureLetter);
    }

  • Questiong in using a model class

    I'm pretty new with the MVC design pattern. When using the model class, I don't know what is the more advantages of using the model class instead of using an application class.
    Moreover, in my application, there are two pages. One is used for searching screen, and the other is used for displaying a result. I try to use the model class to receive all input parameters passed by the view. Everything is fine. After users clicks a search button, a search controller will call the subcontroller which displays a result. At this point, I cannot figure out the best place where calling subcontroller should be. Right now, I put it in the do_request method; nevertheless, I have to detect the search event in this do_request method, as well. In my view, it seems strange! Are there any other solutions or examples matching my problem.

    MVC design pattern is to seperate out different logic. and at the same time keeping them as a seperate entity so that they can be used multiple times(reusability) in different controllers or so.
    yes it is posible to implement the same using application class. like we can make 1 class for mode(business logic) and one for control(class 2) and now make our application class which will inherit these two. this way it will work fine. but in this  yet we are seperating the business and control logic but we are not able to make the act as a seperate entity. the objects  of their type will be live via application class throughout the application.
    and if we make them as a different class instead of inheriting them in application class, and instatiate them whenever require, then that is MVC, that is what we are doing. we are just bypassing application class since we can directly use  class of controller type(super class CL_BSP_CONTROLLER).
    there is no such heirarchy type layering in MVC, these are like three different objects and we are making them communicate to each other so that functionality of each can be seperate out.
    hope this clears your doubt.
    there is a application like you are looking for:
    check it:
    http://help.sap.com/saphelp_erp2004/helpdata/en/12/1eeeb4245d1f4f96c989519261b0f6/frameset.htm
    it is in sap as : bsp application : TUTORIAL_4_MVC  
    it has a controller for searhing search.do
    hope this helps,
    regards,
    Hemendra

  • Model class is initial in subcontroler

    Hello,
    I have a controller class ZCL_ACCOUNT_EDIT which inherits from main controller class ZCL_ACCOUNT_MAIN and this one inherits from CL_BSP_CONTROLLER2. In MAIN I create the object for the model class in DO_INIT
    * create model object:
      acc_model ?= create_model( class_name = 'ZCL_ACCOUNT_MODEL'
                                 model_id   = 'account_model' ).
      set_model( model_id = 'account_model'
                 model_instance = acc_model ).
    * create subcontrolers:
      subedit ?= create_controller( controller_name = 'edit.do'
                                    controller_id   = 'editctrl' ).
    in DO_HANDLE_EVENT I call the controller EDIT.DO like this
    navigation->goto_page('edit.do').
    and it happens that the model class is initial. It seems like the subcontroller is being created again.
    Can someone tell me, what the problem is ??
    Thanks !!

    I found it

Maybe you are looking for

  • Vendor Name in FBL1N report

    Hello, How can we add vendor name in report layout of FBL1N (vendor line item display)? I tried to do define it in additional fields for line item display in customization. But the table LFA1 is not defined in table T021S. Is it possible to add table

  • How do you add an extension to a phone number in iCloud?

    I just attempted to edit a contact's business telephone by adding an extension to the end. Here's what the number looked like to start:  (212) 555-1234 My goal:  (212) 555-1234 x101 What resulted in iCloud when I hit save:  2125551234101 I tried seve

  • TS5150 How can I restore sound to video content streamed to my apple tv?  Used to have sound but now do not.

    I have no sound when I stream videos to my apple tv.  That is a problem when trying to stream concerts or anything.  I downloaded the latest updates, but no change.  I used to be able to do this no problem.  Anyone have any suggestions?  I followed t

  • When I use media manager to upres clip audio goes out of sync

    I captured a clip and put it in DVNTSC 48kHz timeline at OfflineRT NTSC (Photo JPEG) then used the media manager to create a new sequence at full DV NTSC 48kHz res. I choose "Create offline", "set sequences to DV NTSC 48 kHz", and check all the boxes

  • Why is apple maps data different on the mac to the iphone

    basicly there is upto date data on my maps app o nthe mac but when i go and see the same strech of road on my ios device it is the old data. yes this sound picky but i just want to know why, and if it the iphone catche ( if that the right word) how d