How to allow multiple output parameters in a user-defined service operation???

I have creating a self-defined service operation “LDAPAddUser” to connect to LDAP server to create user accounts. I want to get 2 output parameters after executing the operation. One is the result (Boolean data type) and one is the error message (String data type). However, since Java only support one return value in a method, it seems that only one output parameter can be returned. May I have the suggestion so that multiple parameters can be supported in this case? Here is the extracted code
In Java program,
public Boolean addUser(String url, String aName)
In file "component.xml",
     <operation name="addUser" method="addUser" orchestrateable="true" anonymous-access="true">
  <hint>Add a new user</hint>
     <input-parameter name="url" type="java.lang.String" required="true" title="LDAP URL">
     </input-parameter>
          <input-parameter name="aName" type="java.lang.String" required="true" title="Admin Login Name">
     </input-parameter>
          <output-parameter name="Result" title="Result" type="java.lang.Boolean">
          </output-parameter>
Besides the boolean return value, I want to get another return value (string data type). Any suggestion ?

I've returned multiple values to LiveCycle by using a complex object as an intermediatory.
For example if I need to return two strings (firstName and lastName), I'll first build a single class (name) with two string attributes (private String firstName; private String LastName) and add getters and setters to my "name" class for each.  My service class method will return an object of type "name".
for example  public name mymethod(String GUID, String username, String password).......
Then in the component.xml you can return the two strings as long as you use the binding type "Bean":
<output-parameter name="firstName" title="First Name" binding-type="Bean" property="firstName">
                    </output-parameter>
<output-parameter name="lastName" title="Last Name" binding-type="Bean" property="lastName">
                     </output-parameter>

Similar Messages

  • How to view multiple output parameters from web services

    I have used the Labview tool to create a .NET assembly from a WSDL file.
    In the WSDL file the service has been defined to return 2 output parameters.
    In Labview, when I invoke the method for this service the first output parameter ends up as the return value of the method.  I can create an indicator for this and it gets updated properly when I run the VIS to use the web service..  The indicator is an integer value but recognizes the type defined within the WSDL file. 
    The second output parameter shows up as an output value.  When I right click on it and create an indicator for it I get a .NET icon on the front panel rather than an integer value. 
    How can I view the value for this second output parameter after running the web service?
    Is there a difference in how multiple output parameters handled in newer versions of Labview (I am using verison 7.1)?

    scrooge wrote:
    You can try this link .
    the link is dead... or i dont have access..

  • Handling Multiple Output Parameters

    Howdy.
    What is the concensus approach for handling multiple output parameters in Java?
    We have a legacy C API that we are porting to Java. All API routines already return an error value as an int. i.e.:
    int foo(...);
    What if we wanted to return additional info, such as a length and binary (not text) data?
    int foo(...,int* len,char** data);
    We use a char** for data cause we don't know in advance how long the data will be and we don't want callers to have to allocate arbitrary-sized arrays. In other words, we allocate the output data buffer internally.
    How do you do this in Java? Obviously, we can use an Integer object to return the length, but passing in a byte[] for data will not return the internally allocated array to the caller:
    public int foo(...,Integer len,byte[] data); // can't allocate data internally
    We also thought about using ByteArrayOutputStream, but since the class does not provide direct access to the internal array, it requires an inefficient copy through the toByteArray() method in order to retrieve our data.
    Any ideas?
    Ricardo

    Yes, that is the approach that we are currently
    using. We have defined an Out class that incorporates
    all possible output types as data members:Huh? One class that is used for all possible output types? I'm not quite sure what you mean by that. Classes should be meaningful in and of themselves, not just to encapsulate a bunch of unrelated fields. Sounds non-OO.
    public class Out
    byte[] out_bytes;
    int      out_int;
    }I guess we feel this is somewhat inelegant...
    The only real problem is with the byte[] arguments.
    Any thoughts on that?
    Thanks,
    RicardoThere's nothing inherently wrong with a byte array - else there may not be such an animal in the language. Other than the comments above about maybe it being non-OO, the only other comment I could make on this without really seeing the whole context (how this class is really used, etc) would be that yes it looks like it is just encapsulating all possible output types. Not good. If a method is going to return a byte array, it should do so - not return a meaningless "Out" object which happens to contain that array. And another method returning an int should return the int, not this "Out" object containing the int. These don't appear to be related fields belonging to an object in an OO sense.

  • How to generate multiple output pdf's from one oracle reports

    how to generate multiple output pdf's from one oracle reports.
    I have a report where I have to generate more than one output files from the same report based on a parameter.
    Each output file is for each parameter.
    Is this possible in oracle reports, is so how ?

    You can better post your question in the reports forum instead of this pl/sql forum.

  • How to use multiple selection parameters in the data model

    Hi, after have looked all the previous threads about how to use multiple selection parameters , I still have a problem;
    I'm using Oracle BI Publisher 10.1.3.3.2 and I'm tried to define more than one multiple selection parameters inside the data template;
    Inside a simple SQL queries they work perfectly....but inside the data template I have errors.
    My data template is the following (it's very simple...I am just testing how the parameters work):
    <dataTemplate name="Test" defaultPackage="bip_departments_2_parameters">
    <parameters>
    <parameter name="p_dep_2_param" include_in_output="false" datatype="character"/>
    <parameter name="p_loc_1_param" include_in_output="false" datatype="character"/>
    </parameters>
    <dataTrigger name="beforeReport" source="bip_departments_2_parameters.beforeReportTrigger"/>
    <dataQuery>
    <sqlStatement name="Q2">
    <![CDATA[
    select deptno, dname,loc
    from dept
    &p_where_clause
    ]]>
    </sqlStatement>
    </dataQuery>
    <dataStructure>
    <group name="G_DEPT" source="Q2">
    <element name="deptno" value="deptno"/>
    <element name="dname" value="dname"/>
    <element name="loc" value="loc"/>
    </group>
    </dataStructure>
    </dataTemplate>
    The 2 parameters are based on these LOV:
    1) select distinct dname from dept (p_dep_2_param)
    2) select distinct loc from dept (p_loc_1_param)
    and both of them have checked the "Multiple selection" and "Can select all" boxes
    The package I created, in order to use the lexical refence is:
    CREATE OR REPLACE package SCOTT.bip_departments_2_parameters
    as
    p_dep_2_param varchar2(14);
    p_loc_1_param varchar2(20);
    p_where_clause varchar2(100);
    function beforereporttrigger
    return boolean;
    end bip_departments_2_parameters;
    CREATE OR REPLACE package body SCOTT.bip_departments_2_parameters
    as
    function beforereporttrigger
    return boolean
    is
    l_return boolean := true;
    begin
    if (p_dep_2_param is not null) --and (p_loc_1_param is not null)
    then
    p_where_clause := 'where (dname in (' || replace (p_dep_1_param, '''') || ') and loc in (' || replace (p_loc_1_param, '''') || '))';
    else
    p_where_clause := 'where 1=1';
    end if;
    return (l_return);
    end beforereporttrigger;
    end bip_departments_2_parameters;
    As you see, I tried to have only one p_where_clause (with more than one parameter inside)....but it doesn't work...
    Using only the first parameter (based on deptno (which is number), the p_where_clause is: p_where_clause := 'where (deptno in (' || replace (p_dep_2_param, '''') || '))';
    it works perfectly....
    Now I don't know if the problem is the datatype, but I noticed that with a single parameter (deptno is number), the lexical refence (inside the data template) works.....with a varchar parameter it doesn't work....
    So my questions are these:
    1) how can I define the p_where_clause (inside the package) with a single varchar parameter (for example, the department location name)
    2) how can I define the p_where_clause using more than one parameter (for example, the department location name and the department name) not number.
    Thanks in advance for any suggestion
    Alex

    Alex,
    the missing thing in your example is the fact, that if only one value is selected, the parameter has exact this value like BOSTON. If you choose more than one value, the parameter includes the *'*, so that it looks like *'BOSTON','NEW YORK'*. So you need to check in the package, if there's a *,* in the parameter or not. If yes there's more than one value, if not it's only one value or it's null.
    So change your package to (you need to expand your variables)
    create or replace package bip_departments_2_parameters
    as
    p_dep_2_param varchar2(1000);
    p_loc_1_param varchar2(1000);
    p_where_clause varchar2(1000);
    function beforereporttrigger
    return boolean;
    end bip_departments_2_parameters;
    create or replace package body bip_departments_2_parameters
    as
    function beforereporttrigger
    return boolean
    is
    l_return boolean := true;
    begin
    p_where_clause := ' ';
    if p_dep_2_param is not null then
    if instr(p_dep_2_param,',')>0 then
    p_where_clause := 'WHERE DNAME in ('||p_dep_2_param||')';
    else
    p_where_clause := 'WHERE DNAME = '''||p_dep_2_param||'''';
    end if;
    if p_loc_1_param is not null then
    if instr(p_loc_1_param,',')>0 then
    p_where_clause := p_where_clause || ' AND LOC IN ('||p_loc_1_param||')';
    else
    p_where_clause := p_where_clause || ' AND LOC = '''||p_loc_1_param||'''';
    end if;
    end if;
    else
    if p_loc_1_param is not null then
    if instr(p_loc_1_param,',')>0 then
    p_where_clause := p_where_clause || 'WHERE LOC in ('||p_loc_1_param||')';
    else
    p_where_clause := p_where_clause || 'WHERE LOC = '''||p_loc_1_param||'''';
    end if;
    end if;
    end if;
    return (l_return);
    end beforereporttrigger;
    end bip_departments_2_parameters;
    I've written a similar example at http://www.oracle.com/global/de/community/bip/tipps/Dynamische_Queries/index.html ... but it's in german.
    Regards
    Rainer

  • How to allow multiple selection of nodes in a JTree

    How to allow multiple selection of nodes in a JTree ?
    Thanks
    S.Satish

    By default when you create new instance og JTree the selection model is multiple selection. And if you want to change it you use next:
    tee.getSelectionModel().setSelectionMode(TreeSelectionModel.SINGLE_TREE_SELECTION);
    or
    tree.getSelectionModel().setSelectionMode(TreeSelectionModel.CONTIGUOUS_TREE_SELECTION);
    or
    tree.getSelectionModel().setSelectionMode(TreeSelectionModel.DISCONTIGUOUS_TREE_SELECTION);
    Hope will help!

  • How to allow multiple instances of air desktop application

    hi all
    Adobe air desktop application only allow single instance of
    application. How to allow multiple instances like in other desktop
    applications?.
    thanks

    Thanks a lot morgair, i will check with exe4j tool.
    Actually the problem is, thread is not waiting for second request.
    thatswhat i thought it may because of thread.
    Thanks & Regards
    Sudha

  • How to restrict multiple log-ins by same user in SAP BO 4.0

    Hi ,
    Facing licence issue Due to subjected  error  .
    How to restrict multiple log-ins by same user in SAP BO 4.0
    Thanks in advance .

    Then I would say it is not possible:  Restrict multiple login in SAP Business Objects 4.0 SP6 for single user
    multiple login disable in BO | SCN

  • Multiple output-parameters in a custom component

    Is it possible to develop a custom component that returns multiple outputs?
    I know that I can define multiple tag <output-parameter> in component.xml, but I don't know how the method of my class can return multiple Objects...
    Thanks,
    Fabio

    You can have multiple getters and setters function that will set or return multiple parameters. Each output parameter can be set to a specific function.
    Jasmin

  • EXSP24 - How to create multiple outputs

    When using the EXSP24 to play drum samples, is it possible to send different drums to different channels; eg bass drum to one channel, snare to one channel, etc?
    I would like to be able to do this in order to compress drums separately and add low shelf filter to the bass drum only etc.
    I have tried setting up different channel strips for the various drums but this means having the EXSP24 open on each of these tracks, and makes it hard to "play in" drum parts on the keyboard.
    Any suggestions?
    Bern

    You would have to use an EXS instrument that has been assigned to multichannel outputs. I don't know if any of LE7's drum sets are; I'm still using Logic Audio 6. But LA6 includes the EXS Instrument Editor, which allows you to modify existing instruments to make them multichannel; unfortunately, the Editor has been left out of LE7, as I've found out. The Editor is now only included in Pro.
    However, assuming you do have a multichannel drum set, you would select Multichannel (not Mono or Stereo) from the input menu of the Audio Instrument track and select the EXSP24 from there, and load the drumset.
    To access the multiple outputs, you use Aux tracks. You can create more Aux objects in the Environment if you need them. Once the multichannel EXSP24 has been assigned to an Audio Instrument track, the Aux tracks' inputs will either default to the EXSP24's multiple outputs, or have the outputs selectable in their input menus. The Auxes start with output 3; the main 1-2 outputs of the EXSP24 always go through the output of the Instrument track itself.
    Unless you know beforehand how the outputs are assigned, you'll have to play the set a bit to see which Aux track receives which drum(s).
    For example, you could have kick in the main out, snare in Aux 1 (EXSP out 3-4), toms in Aux 2 (EXSP out 5-6), and cymbals in Aux 3 (EXSP out 7-8). This is using stereo Auxes. In the EXS Instrument Editor, sample zones are assignable only to stereo pairs of outputs, not single outputs.
    For even more isolation (each drum to its own output), you'd have to set up the EXS instrument so that each drum is panned hard left or hard right in the pair. Then you create a mono Aux object for each drum; the input menu will then select a single EXSP output.
    I think it's a huge omission (and hindrance to the user) for Apple to leave out the Editor. Not only could you make these changes to your EXS instruments, but you could create new ones from sample CDs - though that's a long process.
    Redmatica's Keymap appears to be a more advanced and easier-to-use alternative to the Editor, but it's not available yet. http://www.redmatica.com/Site/Pages/KM.php

  • How to get multiple output formats for each execution of the report?

    Hi,
    Is it possible to get multiple output formats for each execution of the report? If so can you provide some details?
    Thanks

    In Reports 6i, Reports Distribution was introduced. This allows you to run the report once and output to a number of destinations with a different format. It also allows you to distribute individual sections within a report to different destinations in different formats.
    The Destinations for a Report to distribute to are defined either in a distribution file and passed on the command line or inside of the report definition.
    To add a destination to the the report definition, bring up the property palette against the report object and then select the "Distribution" property under the "Report" node. This will bring up a dialog that allows you to create a distribution list. You can then test this list by selecting "file->distribute" from the menu.
    To run a report that is to be distributed through rwrun60, you need to add "distribute=yes" to the command line. It will pick up the destinations from the report definition. If you add "destination=<filename>" then it will pick up the destinations from the specified "<filename>" and ignore the destinations in the report definition.
    Note: if "distribute=yes" is specified on the command line then the destype/desname/desformat parameters will be used to format the report (ie: which printer/display to use during formatting for sizing objects) but will be ignored when the report is sent to the destinations.

  • How to allow multiple domains under Access-Control-Allow-Origin

    Hi,
    We have a domain where will get CORS request from another domain hosted on seperate DC. We can't set
    Access-Control-Allow-Origin as * due to security concerns & IIS can't take more than 1 value at a time. Kindly suggest how to pass multiple httpheader  for
    Access-Control-Allow-Origin.
    Regards,
    Dhiraj

    Hello Dhiraj,
    This is not the suitable forum for your question, you may post in
    IIS forums for more help.
    Thanks for your understanding.
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Tutorial on how to print  multiple output pages

    Hi,
    I am rather sad that this forum does not provide a simple principle on how to printout multiple pages to newbie.
    Below is a short contribution from me on how to print across multiple pages, other reader are also encourage to modify the code to provide more robust tutorial .
    * How to use java to print across pages that are more than one
    * Short contribution to java forum by Eric gan (Malaysia)
    import java.awt.*;
    import java.awt.geom.*;
    import java.awt.print.*;
    import java.awt.Graphics2D;
    import java.awt.print.*;
    import java.awt.print.Book;
    import java.awt.print.Pageable;
    import java.awt.Graphics2D;
    import java.awt.Graphics;
    public class Example implements Printable {
    //--- Private instances declarations
    private int row_cnt=30; // set the total number of row per page
    private int cum_row_cnt=30; // set the counter to record total number of row per page to determine
    // whether maximum pages should be increase depending on the programme requirement
    private int max_pg=0; // set the maximum number of page
    public Example () {
    //--- Create a printerJob object
    PrinterJob printJob = PrinterJob.getPrinterJob ();
         printJob.setPrintable(Example.this);
    if (printJob.printDialog()) {
    try {
    printJob.print();
    } catch (Exception PrintException) {
    PrintException.printStackTrace();
    public void paint (Graphics g) {
    Graphics2D g2d;
    g2d = (Graphics2D) g;     
    int x=10;
    int y=10;
    for (int outline=0;outline<=160;outline+=20){
              if (y>cum_row_cnt){
              cum_row_cnt+=row_cnt;//counter should grow by value equal to row_cnt
         max_pg++;
         g2d.drawString("outline value ---> " +outline , x, y);
         y+=10; // to set the row printing interval      
    } // end of paint procedure
         public int print(Graphics g,
    PageFormat pf, int pi)
              throws PrinterException {
    // normal routine to check when should java stop the print looping
    if (pi >max_pg) {
    return Printable.NO_SUCH_PAGE;
    Graphics2D g2 = (Graphics2D) g;
         int fontHeight=g2.getFontMetrics().getHeight();
         int fontDesent=g2.getFontMetrics().getDescent();
         double pageHeight = pf.getImageableHeight()-fontHeight;
         double pageWidth = pf.getImageableWidth();
         // setting for the translate and graphics clipping to enable printing on output pages
    // row_cnt can be equal to pageHeight
    // in this examples assumming pageHeight=20 rows           
         g2.translate(pf.getImageableX(), pf.getImageableY());
    g2.translate(0f,-pi*row_cnt);
    g2.setClip(0, (int)(row_cnt* pi),
    (int) Math.ceil(pageWidth),
    (int) Math.ceil(row_cnt));
    paint(g2);
    return Printable.PAGE_EXISTS;
    public static void main (String [] args) {
    Example example = new Example ();
    System.exit (0);
    Thank

    Hello
    I know that Pages is using its own algorithm to resize pages when it put several of them on a single sheet.
    This is why I use this tip.
    I draw a rectangle whose size is supposed to be the final one.
    I give it a white background and a black border whose thickness is set to one point.
    For the tests I just insert three page breaks so that the document is a four pages one.
    I print it as is.
    Doing that, I may measure the printed rectangle.
    Of course, at first attempt it doesn't match the required size.
    It's easy to compute the required adjustments.
    When the correct factor is reached, it is easy to build the complete document so that it prints the correct size.
    Doing that I never got odd results but maybe it's because I am a lucky guy.
    Of course, disagreeing with one advice doesn't mean that I don't respect it.
    I respect your opinion, _on other matters too_
    Yvan KOENIG (from FRANCE mardi 6 mai 2008 17:24:09)

  • How to allow multiple users login to a MAC PRO without interruption?

    I have a mac pro, which runs Yosemite, (2013 module) to be used as a server. However, I have difficult to let multiple users to use the mac simultaneously.
    Objective:
        One person uses the mac directly on his desktop, while the others to login remotely though VNC from PC (win 7/Linux).
        The users have their own workspace, and they will not interrupt each other.
    What I tried:
        I created two mange accounts on the MAC.
        Account 1 was used to directly login on the mac desktop.
        Account 2 was used to login to the mac from a PC though VNC. (I also tried this from a Centos workstation with the Tiger VNC viewer)
    Problem:
    When account 2 is login, the location monitor will automatically change to that account as well. Both accounts shared exactly the same screen, mouse & keyboard actions. It is impossible to let multiple users to use the MAC pro simultaneously without interruptions.
    If I use "hdiutil attach" to mount a dmg file though SSH with account 2, the folder will automatically show in the local desktop login with account 1.
    Question:
    I read something about the "Per-user screen sharing". It says, "You can remotely log into a Mac with any user account on that computer and control it, without interrupting someone else who might be using the computer under a different login." Is it possible to do this from a PC or Linux client?
    If the problem is simply due to the poor functionality of the build-in VNC service in Yosemite, I appreciate your help to suggest some other decent VNC server for Yosemite. I know the Vine Server (OSXvnc), but I failed to install it on the mac because it is incompatible with the Yosemite.
    Does the SSH is supposed to work in this way in OSX? I mean the local account can see the folder mounted by another account though SSH.
    If any specific version of Yosemite is required to allow multiple users to access a mac simultaneously? Just as the win 7 professional allow only one user to login in at each time. But with the remote desktop server of windows, multiple users are able to use the same computer at the same time without any problem.
    If you familiar with any of the above questions, please help. Any comments and suggestions are appreciated.
    I know the best way to get the solution is to direct call the apple support. However, it is really not easy to call them. Because it always results with long waiting time and then the people pick up the phone will transfer my call to an expert who will make me to describe the problem again.
    Since I'm not interested in the technique details of all the problems, it is also grateful if you would provide a direct instruction to let me setup the computer for the purpose.
    Thanks you very much for your kindly help.

    I cannot help with the screen sharing, although I have just tried it with a RealVNC client on an iPad and it seemed to work OK.
    However on the disk showing on all users desk tops have you unchecked the "ignore ownership on this volume" check box? You can check the drives permissions with CMD i command.

  • How to allow multiple wildcard elements in biztalk schema

    Hi,
    In my input xml, I can have one or more unknown elements in the xml. I know I can use <xs:any> in my schema for each of these elements but it does not work when there is unknown number of these unknown elements occuring in the input xml.
    I know the location in xml where these unknown elements appear but I dont know how many times they appear in each location.
    Any help on how to allow it would be very appreciated
    thanks
    manibest

    Hi manibest,
    You're trying to find a technical workaround on how to handle this in schema. But we have to understand that schema is to defining the structure and content of XML and you want a schema which is not going to define the content/structure of your
    XML, its basically a flaw to conceive a Schema which has no relation to the XML.
    Anyway what do you mean by " xml accepted by the schema"  - As mentioned in the
    other post you have raised today, if you don't enforce XML validation and if you don't bother about mapping this unknown fields across to the outbound schema or if your orchestration's processing is not bound to these unknown elements then you can
    do use it.  
    If this answers your question please mark it accordingly. If this post is helpful, please vote as helpful by clicking the upward arrow mark next to my reply.

Maybe you are looking for

  • After pacman -Syu upgrade xfce boots black screen cursor

    Hello, I've recently upgraded the system with pacman -Syu and it seem something has gone wrong with new xfce 4.12. I have changed DM from slim to lxdm and can only boot to openbox but not xfce. I also switch to tty2 and try a startx with ~/.xinitrc f

  • Help me with Hp Probook 4515s

    Hi everybody! (Sorry with my English) I have installed Archlinux x86_64 on my laptop HP Probook 4515s. After installation is completed, restart the computer has been suspended. I also tried with OpenSUSE and Debian, I found the problem in Ethernet ca

  • Hyperlinks don't jump to a second page

    Hello there. Absolute beginner here - DW CS4 on iMac OS10.5.8 I am linking 2 pages via the Properties bar with that folder icon (both pages 'index.html' & 'page1.html' are saved in a site folder, inside a Dreamweaver project folder, inside a folder o

  • Speed Step Setting under XP - when I am NON running on batteries

    Under XPPRO Why does the CPU speed (System Properties, General Tab) measure this: T7600 @ 2.33Ghz, 977 MHz, 2.98 GB of RAM. Except during load it changes to: T7600 @ 2.33Ghz, 2.33 MHz, 2.98 GB of RAM. * During load = running photoshop and makeing the

  • Outlook WebMail Won't Setup

    This might be a tricky one, as I've tried a lot of things, but who knows. My school uses Microsoft Outlook Web Access for its email program. the URL is rockmail.sru.edu/exchange, I've tried setting it up trying all three types of mail (IMAP, POP, Exc