Create Complex Web Service using ADF BC Service Interface

Hi,
We have a requirement to create a number of web services with complex data types. The data types model a logical database entity and therefore contain multiple "rows" of data.
In the most simple example, we have an entity Person and Person Address where 1 person and have multiple person addresses. We need to create a web service that encapsulates these entities and the relationship. For example the web service payload would contain:
+<Person>+
--<firstname/>
--<lastname/>
--<dob/>
--<sx/>
--<address>
----<line1/>
----<line2/>
----<postcode/>
----<country/>
--</address>
+</person>+
We have created ADF BC components for each entity and the relationships. Now we are attempting to use the ADF BC Service Interface functionality to expose web service methods that would create and update the underlying VO/EO/Database tables with one call (i.e. create a record in table Person and one in Person Address).
Creating a service interface for each entity VO works fine but we require a complex service encapsulating the logical entity of Person.
Does anyone know if this is possible with ADF BC Service functionality? Or should we be looking for alternative method of generating these web services?
Any advice greatly appreciated.
Edited by: Jon on Feb 3, 2012 2:50 PM

Hi,
Did you go through following links
http://blogs.oracle.com/middleware/entry/calling_web_services_using_adf_11g
http://st-curriculum.oracle.com/obe/jdev/obe11jdev/ps1/webservices/ws.html

Similar Messages

  • SMS Web Services Using ADF BC

    We would like to implement SMS web services using ADF BC. Could u please help us to point us to the right path to start this. The SMS web services will send the logs, errors or exception generated by Oracle ADF based application to mobile phones. The recipient of this is an IT administrator or those who will maintain the application.
    Aside from the software architecture, what are necessary technical implementation or hardware infrastructure needed to implement this? Is the Oracle wireless already integrated with the Oracle 10g AS?

    Are you already familiar with ADF BC and just trying to implement a web service with it?
    I'm not familiar with what special facility an "SMS Web Service" would need. If you can implement it as a simple java class, you can implement it as a simple java class that uses ADF Business Components for sure.

  • How to create Custom WEB ADI using API Only for both Dowload/Upload process

    I am able to create custom WEB ADI using API for upload process. I have written the following code to create custom WEB ADI using API for upload process.
    DECLARE
    v_application_id NUMBER:= 20003;
    v_object_code VARCHAR2(255):='WEBADI_API_DEM_17';
    v_int_user_name VARCHAR2(255):='WEBADI_API_DEM_17';
    v_language VARCHAR2(255):='US';
    v_source_lang VARCHAR2(255):='US';
    v_user_id NUMBER :=1345;
    v_integrator_code VARCHAR2(255);--:='WEBADI_API_DEM_17_INTG';
    v_param_list_code VARCHAR2(255);
    --v_interface_code  VARCHAR2(255);
    v_interface_code VARCHAR2(255);--:='WEBADI_API_DEM_17_INTF';
    p_layout_code VARCHAR2(255):='WEBADI_API_DEM_17_LAYOUT';
    V_MAPPING_CODE VARCHAR2(255);
    BEGIN
    BNE_INTEGRATOR_UTILS.CREATE_INTEGRATOR(P_APPLICATION_ID =>v_application_id,
    P_OBJECT_CODE =>v_object_code,
    P_INTEGRATOR_USER_NAME =>v_int_user_name,
    P_LANGUAGE =>v_language,
    P_SOURCE_LANGUAGE =>v_source_lang,
    P_USER_ID =>v_user_id,
    P_INTEGRATOR_CODE =>v_integrator_code);
    BNE_INTEGRATOR_UTILS.CREATE_INTERFACE_FOR_API (P_APPLICATION_ID =>v_application_id,
    P_OBJECT_CODE =>v_object_code,
    P_INTEGRATOR_CODE =>v_integrator_code,
    P_API_PACKAGE_NAME =>'XXDH_PRICE_LIST_POC_PKG',
    P_API_PROCEDURE_NAME =>'CREATE_PRICE_LIST',
    P_INTERFACE_USER_NAME =>'WEBADI_API_DEM_17',
    P_PARAM_LIST_NAME =>'WEBADI_API_DEM_17',
    P_API_TYPE =>'PROCEDURE',
    P_API_RETURN_TYPE =>NULL,
    P_UPLOAD_TYPE =>2,
    P_LANGUAGE =>v_language,
    P_SOURCE_LANG =>v_source_lang,
    P_USER_ID =>v_user_id,
    P_PARAM_LIST_CODE =>v_param_list_code,
    P_INTERFACE_CODE =>v_interface_code);
    BNE_INTEGRATOR_UTILS.CREATE_DEFAULT_LAYOUT
    (P_APPLICATION_ID =>v_application_id,
    P_OBJECT_CODE =>v_object_code,
    P_INTEGRATOR_CODE =>v_integrator_code,
    P_INTERFACE_CODE =>v_interface_code,
    P_USER_ID =>v_user_id,
    P_FORCE =>FALSE,
    P_ALL_COLUMNS =>TRUE,
    P_LAYOUT_CODE =>p_layout_code);
    BNE_CONTENT_UTILS.CREATE_CONTENT_COLS_FROM_VIEW (P_APPLICATION_ID =>v_application_id,
    P_CONTENT_CODE =>'WEBADI_API_DEM_17'||'_CNT',
    P_VIEW_NAME =>'XXDH_PRICE_LIST_POC_V',
    P_LANGUAGE =>v_language,
    P_SOURCE_LANGUAGE =>v_source_lang,
    P_USER_ID =>v_user_id);
    BNE_CONTENT_UTILS.CREATE_CONTENT_TO_API_MAP (P_APPLICATION_ID =>v_application_id,
    P_OBJECT_CODE =>v_object_code,
    P_INTEGRATOR_CODE =>v_integrator_code,
    P_CONTENT_CODE =>'WEBADI_API_DEM_17'||'_CNT',
    P_INTERFACE_CODE =>v_interface_code,
    P_LANGUAGE =>v_language,
    P_SOURCE_LANGUAGE =>v_source_lang,
    P_USER_ID =>v_user_id,
    P_MAPPING_CODE =>V_MAPPING_CODE);
    END;
    I need to know what are API we can use to create download+upload ADI? anyone has already prepared script....please share it it me. My email id - [email protected]
    Thanks

    Use FNDLOAD, it's the only way.
    There are 2 seperate scripts, 1 for the Integrator and 1 for Layout.
    FNDLOAD apps/<pw> 0 Y DOWNLOAD $BNE_TOP/patch/115/import/bneintegrator.lct <your name>.ldt BNE_INTEGRATORS INTEGRATOR_ASN="XXX" INTEGRATOR_CODE="<your code>"
    FNDLOAD apps/<pw> 0 Y DOWNLOAD $BNE_TOP/patch/115/import/bnelay.lct <your name>.ldt BNE_LAYOUTS LAYOUT_ASN="XXX" LAYOUT_CODE="<your code>"
    Cheers
    Jeroen

  • Create a Webi report using QAAWS as a data source

    Hi Experts,
    I am on BO 4.1 SP 3, and using the Webi Rich Client to create a WEBi report using a QAAWS url as a data soruce.
    This is the first time I am trying this, so any tips/helpful links are welcome.
    I get the below error, when I try to map the fields. But I do not have any personal data files involved.
    Thanks,
    Vasu Natari.

    Hi Vasu,
    We can create webi report with QAAWS.When creating the report on webservices /Personal data providers we'll not get prompt/query filters option .
    Are you trying to change source ? Instead create new source and get data.

  • Error in Creating Custom Business Methods using ADF Business Comp. Tutorial

    I've been working with Jdev 10g Preview for a while. Now that we have Jdev 10g, I have to unlearn some of the Preview methods and learn the "real" way of doing things. To that end, I went out to the "Creating Custom Business Methods using ADF Business Components" tutorial. Unfortunately, I've found what I think is a mistake in the example code.
    Specifially, ADF treats the default iterator on View Objects differently than previous BC4J versions. In the older versions, the iterator was positioned before the first row when you first executed a query. In that case, the hasNext() method was used to see if you had any rows at all. In ADF, however, the default iterator is positioned at the first row. So, if your query only returns one row, then the hasNext() method returns false!
    Here's the code posted in the tutorial:
    public Number getDeptSalaryTotal(String dept_id)
    // get a department view object
    DepartmentsViewImpl dept = getDepartmentsView1();
    dept.setWhereClause("DEPARTMENT_ID = " + dept_id);
    dept.executeQuery();
    dept.first();
    EmployeesViewImpl emps = getEmployeesView3();
    Number salaryTotal = new Number(0);
    while (emps.hasNext() )
    Row empsRow = emps.next();
    salaryTotal =
    salaryTotal.add((Number)(empsRow.getAttribute("Salary")));
    return salaryTotal;
    As you can see, this is coded using the pre-10g semantics. It checks hasNext() at the top of the while loop. If there is only one Employee in the Department, hasNext() will return false since the emps View Object will already be positioned at the first and only row. There won't be a next row. So, the salaryTotal will be zero instead of the correct value. Alternatively, if there is more than one row, then hasNext() will be true, but the routine will skip the first row and start totalling salaries from the second row on.
    The routine should be recoded as follows:
    public Number getDeptSalaryTotal(String dept_id)
    // get a department view object
    DepartmentsViewImpl dept = getDepartmentsView1();
    dept.setWhereClause("DEPARTMENT_ID = " + dept_id);
    dept.executeQuery();
    dept.first();
    EmployeesViewImpl emps = getEmployeesView3();
    Number salaryTotal = new Number(0);
    Row empsRow = emps.first(); // Get the first row
    while (empsRow != null ) // while we have a row
    salaryTotal =
    salaryTotal.add((Number)(empsRow.getAttribute("Salary"))); // add in the salary
    empsRow = emps.next(); // get the next row
    return salaryTotal;
    I haven't actually executed this code, so there may be a typo or two in there. However, the basic idea is sound -- I think!
    Please update the tutorial so we don't mislead people right at the start! :-)

    Gary:
    I have two questions for you:
    1) Could you post the preferred code here?
    2) Why is it the preferred method? I would think that creating and destroying another object (the temporary iterator) would be a bad thing.

  • Web dynpro using a portal service

    Hello All,
    We are using the JDI.
    We want to use a portal service DC from a web dynpro DC.
    The web dynpro DC is part of a software component.
    When the portal service is a local DC it is working fine (except failing later on the CBS build)
    but when the service is part of a software component as well I get a runtime exception: a java.lang.NullPointerException.
    The WD sharing reference I'm using is: PORTAL:sap.com/<dc service prefix>.<service name>
    I assume that this is the right reference because without this exact phrase I get a java.lang.NoClassDefFoundError: com/sap/<name of service>
    <b>Does anybody know how to use a portal service that is part of software component?</b>
    Thanks a lot in advance, Adi.

    Thanks Bharathwaj , but I already solved my problem.
    The solution was  to change the next code line in the service client code :
    Idb_srv DB_Service = (Idb_srv) WDPortalUtils.getServiceReference(Idb_srv.KEY)
    to:
    Idb_srv DB_Service = (Idb_srv) WDPortalUtils.getServiceReference(""<PARFilename>.<service name>");
    Regards, Adi.

  • Create a nice look web site using adf

    Dear Experts,
    I really trying to find a very useful tutorial to create a nice look website using adf, but I didn't find a complete tutorial , please share your experience with us.

    go here
    http://subu-jdeveloper11gadf.blogspot.in/search?updated-max=2011-12-28T17:12:00%2B05:30&max-results=1&start=1&by-date=false
    Edited by: ADF7 on Mar 18, 2012 8:47 PM

  • How to create a floating layout using adf

    Hi ,
    I am using Jdeveloper 11g to develop an application.
    I am coming across problems when i am trying to build the look and feel.
    Basically i want to develop as per the following link.
    http://webfusion.kcmo.org/coldfusionapps/ActionCenterRequest/getstatus.cfm
    I have been able to create the layout using adf layouts and components(af:panelStechlayout, af:panelgrouplayout), but the problem i am facing is that i want the entire page to scroll and have a floating layout.
    But in my case, the panels are scrolling, so when i resize the browser or change the resolution, everything appears to be broken in parts.
    Besides to recreate the above layout i have to include everything under the "center" facet, hence using templates is creating issues.
    following is the code i am using(just the structure code), this looks preety simple but i am not able to figure this one out.
    <?xml version='1.0' encoding='UTF-8'?>
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.1"
              xmlns:f="http://java.sun.com/jsf/core"
              xmlns:h="http://java.sun.com/jsf/html"
              xmlns:af="http://xmlns.oracle.com/adf/faces/rich">
      <jsp:directive.page contentType="text/html;charset=UTF-8"/>
      <f:view>
        <af:document title="findcase" id="d1">
          <af:form id="f1">
            <af:panelStretchLayout startWidth="100px" endWidth="100px" id="psl2">
              <f:facet name="center">
                <af:panelStretchLayout endWidth="63px" id="psl1"  topHeight="120px" bottomHeight="50px"
                inlineStyle="font: 100% Arial, Helvetica, sans-serif;background: #2A3644;font-size: 13px;margin: 0;padding: 0;text-align: center;color: #000000;"
                                       startWidth="44px">
                  <f:facet name="center">
                   <!-- Header -->
                   <af:panelGroupLayout layout="scroll"
                                         xmlns:af="http://xmlns.oracle.com/adf/faces/rich"
                                         id="pgl3">
                      <af:image source="http://cfdev.kcmo.org/coldfusionapps/templates/images/kcmo_banner.jpg"
                                shortDesc="header" id="i1"
                                inlineStyle="width:960px; height:77.0px;"/>
                      <af:panelGroupLayout id="pgl2" inlineStyle="height:33.0px;">
                        <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/home.jpg"
                                  shortDesc="menu1" id="i2"/>
                        <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/services.jpg"
                                  shortDesc="menu2" id="i3"/>
                        <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/residents.jpg"
                                  shortDesc="menu3" id="i4"/>
                        <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/business.jpg"
                                  shortDesc="menu4" id="i5"/>
                        <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/visitors2.jpg"
                                  shortDesc="menu5" id="i6"/>
                        <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/officials2.jpg"
                                  shortDesc="menu6" id="i7"/>
                        <!--af:panelGroupLayout id="pgl4"-->
                          <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/kcmo_banner_slice.jpg"
                                    shortDesc="searcharea" id="i8"
                                    inlineStyle="background-repeat:repeat; width:355px; height:35.0px;"/>
                        <!--/af:panelGroupLayout-->
                        <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/kcmo_banner_lower.jpg"
                                  shortDesc="banner" id="i9"
                                  inlineStyle="width:960px; height:7.0px;"/>
                      </af:panelGroupLayout>
                     <!-- starting the center section -->
                      <af:panelStretchLayout id="psl3" inlineStyle="width:960px; margin:auto; background-color:White;"
                                             startWidth="232px">
                        <f:facet name="center">
                         <!-- your page content goes here -->
                          <af:outputText value="outputText1" id="ot3"/>
                        </f:facet>
                       <!-- side navigation panel -->
                        <f:facet name="start">
                          <af:panelGroupLayout id="pgl1" inlineStyle="float:left; margin:5px; width:236.0px;background-color:#edf0f5;text-align: center;">
                           <af:goLink text="City Government" id="gl1"
                                   destination="http://www.kcmo.org/CKCMO/Depts/CityManagersOffice/InternshipsandfellowshipswiththeCity/KansasCityGovernment/index.htm"
                                   inlineStyle="font-family:Arial, Helvetica, sans-serif; font-size:10px;     color:#395F76;     font-weight:bold;"/>
                          <br/>
                            <af:goLink text="Codes and Ordinances" id="gl2"
                                       destination="http://cityclerk.kcmo.org/liveweb/common/"
                                       targetFrame="_blank"/>
                          </af:panelGroupLayout>
                        </f:facet>
                        <f:facet name="end"/>
                      </af:panelStretchLayout>
                    </af:panelGroupLayout>
                  </f:facet>
                  <f:facet name="end">
                    <af:outputText value="" id="ot2"/>
                  </f:facet>
                   <f:facet name="start">
                <af:outputText value="" id="ot1"/>
              </f:facet>
                </af:panelStretchLayout>
              </f:facet>
            </af:panelStretchLayout>
          </af:form>
        </af:document>
      </f:view>
    </jsp:root>Any help will be highly appreciated.
    Thanks in advance
    Ash

    Try creating a layout that uses a panelGroup scroll as the top container and use panelBorders inside it.
    Something like this:
    <?xml version='1.0' encoding='windows-1252'?>
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.1"
              xmlns:f="http://java.sun.com/jsf/core"
              xmlns:h="http://java.sun.com/jsf/html"
              xmlns:af="http://xmlns.oracle.com/adf/faces/rich">
      <jsp:directive.page contentType="text/html;charset=windows-1252"/>
      <f:view>
        <af:document id="d1">
          <af:form id="f1">
            <af:panelGroupLayout layout="scroll" id="pgl1">
              <af:panelBorderLayout id="pbl1">
                <f:facet name="start"/>
                <f:facet name="bottom"/>
                <f:facet name="end"/>
                <f:facet name="top">
                  <af:panelGroupLayout layout="scroll"
                                       xmlns:af="http://xmlns.oracle.com/adf/faces/rich"
                                       id="pgl3">
                    <af:image source="http://cfdev.kcmo.org/coldfusionapps/templates/images/kcmo_banner.jpg"
                              shortDesc="header" id="i1"
                              inlineStyle="width:960px; height:77.0px;"/>
                    <af:panelGroupLayout id="pgl2" inlineStyle="height:33.0px;">
                      <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/home.jpg"
                                shortDesc="menu1" id="i2"/>
                      <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/services.jpg"
                                shortDesc="menu2" id="i3"/>
                      <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/residents.jpg"
                                shortDesc="menu3" id="i4"/>
                      <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/business.jpg"
                                shortDesc="menu4" id="i5"/>
                      <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/visitors2.jpg"
                                shortDesc="menu5" id="i6"/>
                      <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/officials2.jpg"
                                shortDesc="menu6" id="i7"/>
                      <!--af:panelGroupLayout id="pgl4"-->
                      <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/kcmo_banner_slice.jpg"
                                shortDesc="searcharea" id="i8"
                                inlineStyle="background-repeat:repeat; width:355px; height:35.0px;"/>
                      <!--/af:panelGroupLayout-->
                      <af:image source="http://webfusion.kcmo.org/coldfusionapps/templates/images/kcmo_banner_lower.jpg"
                                shortDesc="banner" id="i9"
                                inlineStyle="width:960px; height:7.0px;"/>
                    </af:panelGroupLayout>
                  </af:panelGroupLayout>
                </f:facet>
                <af:panelBorderLayout id="pbl2">
                  <f:facet name="start">
                    <af:panelGroupLayout id="pgl4" layout="scroll">
                      <af:commandLink text="menu1" id="cl1"/>
                      <af:commandLink text="menu2" id="cl2"/>
                    </af:panelGroupLayout>
                  </f:facet>
                  <f:facet name="bottom"/>
                  <f:facet name="end"/>
                  <f:facet name="top"/>
                  <af:panelFormLayout id="pfl1">
                    <f:facet name="footer"/>
                    <af:inputText label="Label 2" id="it2"/>
                    <af:inputText label="Label 1" id="it1"/>
                  </af:panelFormLayout>
                </af:panelBorderLayout>
              </af:panelBorderLayout>
            </af:panelGroupLayout>
          </af:form>
        </af:document>
      </f:view>
    </jsp:root>

  • Stdout/stderr for NT service using com.ms.service

    Hi,
    I have a Windows NT service created using com.ms.service
    I was wondering where are System.out and System.err pointed.
    Searched for "log", "out", "err" files with the name of service but nothing found. Also searched for services.log etc.
    TIA

    Here is another tool that enables you to run Java applications as Windows services: http://www.alexandriasc.com/software/JavaService/index.html
    Jesper

  • How to create a movable box using adf faces (without using oracle composer)

    Hello All,
    I am new to adf and i need to create a movable box . A box which the user can move anywhere he wants on the page and he should be able to minimize and maximize it.
    (ex:igoogle).
    According to my requirements i need to do it using adf components
    any help please

    Hi,
    as you need to persist the user change, you will need to have a look at MDS. See 31 at http://www.oracle.com/technetwork/developer-tools/adf/learnmore/index-101235.html
    It has a createDepartments.jspx page that allows users to move the input text fields around. You can use code similar to the one used here to move panelBoxes
    Frank

  • Started creating a web site using iWeb, signed up for MobileMe trial, now iWeb won't work?

    So I started playing around with iWeb and created a web site for my portfolio. I then signed up for a trial of the MobileMe. After I went through the whole setup process for MobileMe...setting up on my iPod Touch, then on my iMac, then syncing all the apps...I back to iWeb to publish my web site to my newly created MobileMe account. Only iWeb was unresponsive. I tried to restart the application. I get as far as the welcome screen with the "Getting Started Video", but there is no iWeb window open behind that. I tried to restart my machine...nothing!
    Now I have this MobileMe trial that is ticking away and I can't even use it. Please help, thanks.
    grafxboy.mac

    Update. After a conversation with Marlon at Apple Support, we have it resolved. As soon as I mentioned that iWeb would launch properly on other profiles, we figured out that it has to be a preference problem. I should have known better, its one of the first things to check. But, I've been away from macs for a little bit, so I'm a little rusty in the troubleshooting dept.
    To trash iWeb preferences:
    1) Quit iWeb
    2) Navigate to:
    User Directory --> Library --> Preferences  --> com.apple.iWeb.plist
    3) Take this file and drag it to your desktop
    4) Relaunch iWeb
    5) If everything works as it should, you can take the preference file you dragged to your desktop and move it to      the recycle bin.
    Somewhere in the MobileMe registration and setup process the preferences for iWeb froze up. Trashing the iWeb preferences fixed the problem.
    If I come across any issues posting site to MM or posting site updates to MM I will update this thread.

  • Application Services uses other application Services like business Object

    Hallo
    I use the SAP NetWeaver 7.1 SP3.
    One question can i use in the Applcation Service another Application Service (not Business Object)?
    The reasons I want to have this possibility:
    If I use the external service and I will be exposed as a new Applicaiton Service, thus it can be used by several application Services.
    I have put one Application Service A into the dependency of Application Service B... but in code i can not find out the API to lauch to the Application B.
    Thanks and Kind Regards
    Ping

    Thanks
    But I can not find  the Object ApplicationServiceALocal
    and the code
    ApplicationServiceALocal appServiceA = this.getApplicationServiceA();
    I can not get it.
    Maybe I should after the add dependency Generate Application, buîld Application?
    Kind Regards
    Ping

  • Create-Edit-Delete page using ADF Faces & Toplink

    Hi,
    i want to build simple apps like this one : http://andrejusb.blogspot.com/2007/06/create-edit-and-delete-operations-in.html
    It's using ADF BC. How could it be done using ADF Toplink ?
    Thanks,
    Best Regards,
    Ricky

    Ricky,
    If you're using JDeveloper 10.1.3, take a look at the ADF learning center. Under the heading "Experienced Java Developers", on the right, you'll see a sample, tutorial and developer guide covering the ADF Faces/TopLink technology stack.
    Blaise

  • Help! with creating a J2ME program using the http connectivity interface

    So this is what I have to do using the http connectivity interface:
    1.Creating two threads – one for communication (receiving and sending) and the other (main) thread will be for interaction with the user.
    2.The main thread will make use of three midlet forms. The first form will ask for web page address (URL) and separately for a delimiter which will separate the words in the URL document, the third form will display the ratio of all symbols on the page and the number of occurrences of the delimiter specified
    3.The second thread should perform http connectivity to the WWW, utilise the web page address supplied and connect to the appropriate web page and read its content, count all symbols on the chosen page, count the number of occurrences of the delimiter given as user input on the same form as the web page address, calculate the ratio between the two and pass this information to the first thread to display.
    I have many questions but my main concerns are:
    *1. How to communicate using HTTP interface within a thread*
    *2. What is a delimiter in the context above and how should it be implemented*
    I've been thrown in at the deep end with little programming experience with this assignment. If anyone can share a similar example or answer my concerns I'd be more than happy.
    Thanks in advance.

    thelane wrote:
    hi thanks for the response.
    As I said I have coded in other languages before, but this is a new for me in java. I needed to get it working quickley. Now I can clean up.
    I will have a look at method and see how I get on.
    ANy similiar examples would be great.
    Thanks.I can certainly give you a similar example.
    Say you have code such as this:
      int a = 10, b = 11;
      int temp = 1;
      for(int i = 2; i < a; ++i) {
       temp *= i;
      System.out.println(a + " factorial is " + temp);
      temp = 1;
      for(int i = 2; i < b; ++i) {
       temp *= i;
      System.out.println(b + " factorial is " + temp);Each section of code takes the factorial of the current variable an outputs it. The factorial code can be placed within a method to be called more easily, as such:
    public void factorial(int num) {
    int temp = 1;
    for(int i = 2; i < num; ++i) {
      temp *= i
    System.out.println(num + " factorial is " + temp);
    }Then, whenever you need to call it, you can just do so:
    int a=10,b=11,c=12;
    factorial(a);
    factorial(b);
    factorial(c);

  • Unable to create records in database using PHP Data Service

    Hello, I've been stuck on this for a few days and search up and down for this on the net, no response I've found has worked, so I come to you...
    Here are the steps I've taken, I think it's pretty standard
    1. I have a macbook pro running osx 10.7.3
    2. I installed MAMP all default (I've acually reinstalled this because someone suggested this might fix it)
    3. Thru phpMyAdmin I created a database called my_test
    4. In that database I created a table, this is the export of that table: (I've also tried this with InnoDB which is the default)
    CREATE TABLE `customer` (
      `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
      `name` varchar(50) NOT NULL,
      `email` varchar(150) NOT NULL,
      PRIMARY KEY (`id`),
      UNIQUE KEY `id` (`id`)
    ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;
    5. I created a new Flx Project (Running Flash Builder 4.5.1 Premium)
         Project Name: PHPTest
         Application Type: Desktop (Although I've done the same thing with Web and got the same results)
         >> Next
         Application Server Type: PHP
         Web Root: /Applications/MAMP/htdocs/
         URL Root: http://localhost:8888/
         Clicked 'Validate Configuration' and that worked
         Output Folder: /Applications/MAMP/htdocs/PHPService (default by Flash Builder)
         >> Finished
    6. On the Data/Services tab on the bottom I click 'Connect to Data/Service...'
         Select 'PHP'
         >> Next
         Select 'Click here to generate a sample'
         Select 'Generate from database' radio button
         Username: root
         Password: root (default for MAMP)
         Host name: localhost
         Server port: 8889 (default for MAMP MySQL port, the HTTP port default is 8888 which in both cases seem to work but every video I've seen that uses MAMP on youtube uses 8889)
         Database: my_test
         Click 'Test Connection' (works)
         Table: customer
         Primary Key: id (this field is greyed out and Flash Builder selects 'id' which it figures out from the SQL table)
         >> Click OK
    7. Then if I don't have the Zend Framework folder in my /Applications/MAMP/htdocs/ folder it tells me its going to create that and I say alright. Then Flash Builder says stuff about how this is really only for testing and not production server ready and I say alright.
    8. Then it takes me back to the Form from Step 6 when I get the chance to select 'Click here to generate a sample'
         These fields are now filled with this data automaticly:
         PHP Class: /Applications/MAMP/htdocs/PHPTest/services/CustomerService.php
         Service name: CustomerService
         Service package: services.customerservice
         Data type package: valueObjects
         >> Click Next (shows all the functions that will be now availible)
         >> Click Finished (End of the forms and it opens Dreamweaver to the php file it created CustomerService.php which I have no need to edit so I close that down)
    9. Back in Flash Builder I switch to design view and drag a datagrid onto the big white area in the middle, whatever that is called.
    10. Then below in Data/Services tab on the bottom I click drag the function 'GetAllCustomer' on top of the datagrid.
         I say yes to rebound and click ok and the view of the datagrid is updated with the colums from the 'customer' table in mySQL.
    (Now let me say that when I hit save and compile this, if I actually had records in this table that I insert thru phpMyAdmin, this does show in the datagrid. So for the whole CRUD thing I am able to get the R which is Read)
    11. Now going back to the design view in Flash Builder I will create a form to create records in the table... (I guess this isn't really a step)
    12. In the Data/Service tab on the bottom I select 'createCustomer' function and then there is an icon called 'Generate Form' that looks like a white piece of paper with a gear on the bottom of it.
    13. This opens up a new form and since I don't have a crazy bunch of fields in my table I just click Finished (If you click next you can specify which fields you want to exclude from the form but this time I don't need to)
    14. This actually creates 2 forms if you look at the code, the second just shows the return type from when you click 'CreateCustomer' button on the first form. Because they overlap in design view I drag the form out of the way so you can see the input form, the return form, and the datagrid
    15. Then I save and compile...
    (Also if your actually reading this I didn't remove the id form field, I get the same result either way, but if you do remove the form field in the code/design you also have to update the button function to not deal with the id before it gets sent off to the php page since in this case the MySQL table is set to auto_increment the id, sorry this doesn't make much sence but this little area doesn't matter much either way)
    16. Now fill in whatever data you want for name and email, try differnt numbers in the id field like 0, nothing, 1, 1000 and click 'CreateCustomer'
    (For me nothing happens, no return is put in the return field, no error pops up and the datagrid is not updated with the new record, also going over to phpMyAdmin and checking out the table browse doesn't show any changes either, I know the button is calling the function because if I add a state change in that function it changes, it would seem that the line:
    createCustomerResult.token = customerService.createCustomer(customer2); doesn't do anything)
    So any idea what is wrong here, I'm convenced it's something stupid easy simple I just can't see it.

    In case you need more info, here is a code dump on a mxml project that has this problem:
    <?xml version="1.0" encoding="utf-8"?>
    <s:WindowedApplication xmlns:fx="http://ns.adobe.com/mxml/2009"
                           xmlns:s="library://ns.adobe.com/flex/spark"
                           xmlns:mx="library://ns.adobe.com/flex/mx"
                           xmlns:customerservice="services.customerservice.*"
                           xmlns:valueObjects="valueObjects.*"
                           currentState="State1">
        <fx:Script>
            <![CDATA[
                import mx.controls.Alert;
                import mx.events.FlexEvent;
                protected function dataGrid_creationCompleteHandler(event:FlexEvent):void
                    getAllCustomerResult.token = customerService.getAllCustomer();
                protected function button_clickHandler(event:MouseEvent):void
                    var customer2:Customer = new Customer();
                    customer2.id = parseInt(idTextInput.text);
                    customer2.name = nameTextInput.text;
                    customer2.email = emailTextInput.text;
                    currentState = "Test";
                    createCustomerResult.token = customerService.createCustomer(customer2);
            ]]>
        </fx:Script>
        <s:states>
            <s:State name="State1"/>
            <s:State name="Test"/>
        </s:states>
        <fx:Declarations>
            <s:CallResponder id="getAllCustomerResult"/>
            <customerservice:CustomerService id="customerService"
                                             fault="Alert.show(event.fault.faultString + '\n' + event.fault.faultDetail)"
                                             showBusyCursor="true"/>
            <valueObjects:Customer id="customer"/>
            <s:CallResponder id="createCustomerResult"/>
            <!-- Place non-visual elements (e.g., services, value objects) here -->
        </fx:Declarations>
        <s:DataGrid id="dataGrid" includeIn="State1" x="330" y="10" width="392"
                    creationComplete="dataGrid_creationCompleteHandler(event)" requestedRowCount="4">
            <s:columns>
                <s:ArrayList>
                    <s:GridColumn dataField="id" headerText="id"></s:GridColumn>
                    <s:GridColumn dataField="name" headerText="name"></s:GridColumn>
                    <s:GridColumn dataField="email" headerText="email"></s:GridColumn>
                </s:ArrayList>
            </s:columns>
            <s:typicalItem>
                <fx:Object id="id1" email="email1" name="name1"></fx:Object>
            </s:typicalItem>
            <s:AsyncListView list="{getAllCustomerResult.lastResult}"/>
        </s:DataGrid>
        <s:Form includeIn="State1" defaultButton="{button}">
            <s:FormItem label="Id">
                <s:TextInput id="idTextInput" text="{customer.id}"/>
            </s:FormItem>
            <s:FormItem label="Name">
                <s:TextInput id="nameTextInput" text="{customer.name}"/>
            </s:FormItem>
            <s:FormItem label="Email">
                <s:TextInput id="emailTextInput" text="{customer.email}"/>
            </s:FormItem>
            <s:Button id="button" label="CreateCustomer" click="button_clickHandler(event)"/>
        </s:Form>
        <s:Form includeIn="State1" x="0" y="204">
            <s:FormItem label="CreateCustomer">
                <s:TextInput id="createCustomerTextInput" text="{createCustomerResult.lastResult as int}"/>
            </s:FormItem>
        </s:Form>
    </s:WindowedApplication>

Maybe you are looking for

  • I have upgraded to Maverick when i connect an external hard drive my security does not scan it now

    I have upgraded to Maverick.  With snow leopard when I connected an external hard drive, the Norton security would scan this drive. Since I have had Maverick this does not happen, I have updated my security.

  • Dynamic menu css not displaying correctly in https

    Hello, Need help! I'm trying to get my menu to display properly in https but no luck so far. (Chrome and IE) Please let me know if there is a solution. Thank you. good menu look http://winxed.businesscatalyst.com/ bad menu look https://winxed.worldse

  • EPub format and pinch-and-zoom

    Hello all,   I'm curious if someone can tell me whether the pinch-and-zoom capability seen on the IPad is a function of the hardware, or is it something that needs to be dealt with in advance in the ePub document? I wouldn't mind having images that a

  • ICM7.5 - System is shutting down with a error message

    Hi, I have installed a ICM7.5 SPRAWLER in our Lab.All was working fine until yesterday, when I suddenly started receiving the below error This system is shutting down. Please save all work in progress and log off. Any unsaved changes will be lost. Th

  • Enhancement Request in Project Libraries and Classpath dialog

    Hello, in the Libraries and Classpath section of the Project Properties we can move up/down single classpath entries only. Adding some libraries and ordering them is pretty much work. Please allow moving multiple selected entries (this was possible i