Storing global variable

Hey there
I'm trying to figure out how/if you can store a global variable, for access in all classes of the program. In this case I am developing an app which connects to a database. At the moment each class makes a seperate connection to the database for it's purposes, but I would rather make one connection at the beginning, and then each class shares this connection. I realise I can do this by having each class constructor accept a connection, and then just threading the connection to all of them. However, is there a way I can just store that connection somewhere in memory, and access it from all classes. I remember being able to do this in C# so hopefully Java has something similar.
Thanks
Nathan

I don't know how this got into the JDBC forum, but a
basic way of making a "global" variable is like
this:public class User {
public static Connection theConnection;
}Then other classes access it like
this:Connection conn =
User.theConnection;When you learn some Java
you'll find out that this is primitive programming and
there are better ways, but this will do for a raw
beginner.It's quite sad that you say this, I have been using java in my degree for the last 3 years. I guess we haven't developed applications from scratch, but I've done tons and tons of assignments in Java. The fact that I'm still at raw beginner level scares me. Perhaps I should not be looking for a programming job next year.

Similar Messages

  • How to pass global variables to call stored procedure in form personalizati

    Hi,
    We want to call a custom store procedure with 2 paramterts, I am storing values into 2 global variables.
    We want call the custom store procedure with global variable values in form personalizations.
    We tried like
    ='declare
    begin
    SUR_TEST_ORDER_LINE_UPD.update_order_line (:global.xx_line_id, :global.ship_set_id);
    end'
    Could you please suggest.
    Advance Thanks
    Subbu

    Hi,
    Doc number (MOS Doc 743490.) is avaiable in metalink or ?Yes.
    Note: 743490.1 - Customization in Oracle Applications
    https://metalink2.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=743490.1
    Regards,
    Hussein

  • Storing DAQmx Task in a Functional Global variable

    Happy New Year to everyone!
    I got a nice little question hoping some of you might be able to help me....
    After initializing an starting a DAQmx task (V7.5), I wanted to store the task out reference in a functional global variable, but it seems, it didn't work.
    Everytime I tried to call a DAQmx VI with the opened reference, I get an error, the task would not be existing....
    I already made a workaround, so everything works fine. I'm just curious what I made wrong....
    Thanks in advance!
    Cheers
    Oli
    Programming languages don't create bad code, programmers create bad code....

    Helo Oli,
    Normally, you should not have a problem storing a task reference in a variable. However, the vi that created the task has to stay in memory for it to work. Closing the vi will result in the destruction of all created hadles -
    that is why your reference might be regarded invalid if you use it in
    another vi.
    That is why I can just assume that you are closing the VI that created the task before you are using the handle somewhere else. You can use variables to store the task ID, but as a workaround you have to keep the vi which reated the reference running.
    Hope this explains the behaviour.
    Regards
    Ingo Schumacher
    Systems Engineer Sound&VibrationNational Instruments Germany

  • Dynamic call of a vi with a reference stored in a global variable

    Hello,
    I am trying to program a VI which calls DAQmx functions in some cases, in other cases DAQmx may not even be installed. To prevent a broken arrow on machines where DAQmx is not installed, I want to use a sub-VI containing the DAQmx function calls which is called dynamically by a main VI. For speed I want to prevent continuous opening and closing the VI reference, so I want to store the reference to the sub VI in a global variable. In this variable I also want to store the Analog Input Task. I want to use an initialization VI to write the VI reference of the sub VI and to configure and start the Analog Input Task and write the Task ID to that Global, too. In that way I was hoping to be able to improve the performance of the dynamic calls and the Task calls. BUT - when I write the refererence and task to the Global and read it out from another VI, the reference is not valid anymore and the Analog Input task is also not valid, even if both the initialization VI and the Global are still open (but not running). Does somebody have an idea how to solve that? It is a bit difficult to describe, so here is what I want to do in a shorter description :
    - run a initialization VI which
      defines a reference to a sub VI which will be called dynamically later on
      and a AI task ID definining a DAQmx physical channel configuration to use for subsequent read cycles
      and writes both (VI reference and AI task) to a global variable
    - run another VI which
      reads the VI reference of the VI to call dynamically from that global
      runs the corresponding VI dynamically
      the dynamically called VI performs an AI task corresponding to the DAQmx task ID read from that global (it reads an analog value for instance from the  
      physical channel configured by that AI task) 
    Why all that? To prevent creating and destroying the VI reference for each call of the sub VI for speed. And to use the configured DAQmx channel for subsequent read tasks only if the subVI is called dynamically - if it is not, then the application will not see the DAQmx calls and therefore no broken arrow will occur if no DAQmx is installed on the machine.
    Can somebody help me with this? Why can't I store and read out the reference to the sub VI to/from a global, and why is the AI task not valid when read out from the dynamically called sub VI? I am somewhat lost with all that...
    Thanks in advance,
    Gabs

    Uh - I am almost getting crazy with that
    Kevin, that solution is the right one for programming an application. In that case everything will work fine. But during testing, it is more convenient to call all VIs from their front panels one after another. That's how I'm doing it for everything that needs to be exchanged between such VIs: store them either in a global or in a functional global variable. In that way the user can "play around" with the VIs without wiring them together in a main VI. Therefore, after some thinking I liked Davids idea with that daemon VI (I solved that by adding a boolean in the initialization VI to choose if that daemon is necessary - during testing phase - or not - when using the VIs in a main application). BUT:
    David: It does not work!!! I have exactly done what you proposed and this daemon VI is really running, having a True/False frame with a constant of False wired to the selector and holding both the functional global and the dynamically to call VI in the True frame. In that way, after initialization is finished, both VIs are still running but idle. Anyway, when I read back the value of the reference or the DAQmx task, it is invalid again!
    That really costs just too much time. Does anybody have any idea what to do now? David, I was hoping that your suggestion would solve the problem, because it would be logical that it would - why then is LabVIEW destroying the reference and task anyway even if that daemon VI containing the functional global is still running???
    Regards,
    Gabs

  • Java Threads vs. Native Global Variables

    A brief description of the problem:
    I am trying to integrate a multi-threaded Java app with legacy Fortran code. The Fortran code in question makes extensive use of global variables in the form of Fortran's Common Block data structure.
    If multiple threads were allowed access to a native routine, they would over write each others data which is stored in global variables.
    If only one thread at a time can have access to the native routine for the duration of the native routine, the whole advantage of using threads is completely nullified.
    These native routines cannot be rewritten (3rd party code) and must be used.
    One solution I envisioned was to load a new copy of the native shared object code for each Java object that used the native code. However, it seems System.loadLibrary() can only be used in a static context.
    Is there any known solution to this problem?

    Here is an elaboration on the earlier suggestions. It's a high overhead solution, because you have to start a bunch of JVMs.
    1. You have a java control program, which will start up a pool of "services", make requests to them, and gather the results.
    2. Each service is a small java program with a native method:
    o java communications front-end.
    o native method declaration.
    o native - in your case fortran - method implementation.
    3. Each service is started using "exec". That puts it in a separate process.
    4, Since each service is a java program, you can use java to do communications between the control program and the service.
    o You could use RMI.
    o You could - perhaps - use java Process communications, i.e., have the services write to stdout, and have the control program capture the output.
    o You could use socket communications.

  • How do I add a global variable to my app?

    Hi all,
    I am building a flex app which displays data in different tabs from a mysql database and I wan't to add a sign in process to make sure only registered users of the mysql db can see the data.
    To achieve this I built a sign in component which accepts a username, password and the name of the database to connect to. My flex app then uses a php script to verify that the user can connect to the database using the details entered. If not, the sign in component displays an error message, but if sign in details are verified then the user can see the data from the database.
    How can I store the details in the flex app for that users session so that when the user queries the db for data, flex uses the details entered during the sign in process to connect to the mysql db and submit the query?
    I thought about storing the details as an array in a global variable and then accessing that global variable from anywhere in my app but I don't know if that is the correct/secure way to do what I want, nor do I know how to do it. Any help would be much appreciated.
    Thanks in advance,
    xander

    quick, dirty example, could be improved on but it'll get you rolling;
    After user login has succeeded, send off another HTTP service eg;
    ========
    <mx:Script>
             <![CDATA[
                public var whateverUserNameWasEntered:String;
                 public var whateverUserPasswordEntered:String;
         public function onLoginSuccess():void
              whateverUserNameWasEntered:String = loginbox.text;
              whateverUserPasswordEntered:String = passwordbox.text;
              storeSessionStuff.send();
         ]]>
        </mx:Script>
    <mx:HTTPService id="storeSessionStuff" showBusyCursor="true" method="POST"  url="http://localhost/store.php" useProxy="false">
            <mx:request xmlns="">   
              <username>
                   {whateverUserNameWasEntered}
              </username>
              <password>
                   {whateverUserPasswordEntered}
              </password>       
            </mx:request>
        </mx:HTTPService>          
    ========
    direct it to the php file.....
    <?php
    session_start();
    $_SESSION['username'] = $_POST['username'];
    $_SESSION['password']   = $_POST['password'];
    ?>
    Then, whenever you want to get the information out of the Session, send off another HTTP Service...;
    <mx:HTTPService id="getSessionStuff" result="storeData(event)" showBusyCursor="true" method="POST"  url="http://localhost/get.php" useProxy="false"/>
    to the php file....
    <?php
    session_start();
    print "<details><username>".$_SESSION['username']."</username><password>".$_SESSION['password'] ."</password></details>";
    ?>
    which, you need a result function for:
    <mx:Script>
             <![CDATA[
              private function storeData(evt:ResultEvent):void
                    var username:String;
                    var password: String;
                   username = evt.result.details.username;    
                   password = evt.result.details.password;         
          ]]>
    </mx:Script>
    ta daa
    (if thats what you meant)

  • Global variables for order header attributes ?

    Hi Experts,
    What are the names of the global variables that stores the values of order header attributes till the order creation ?
    Thanks!

    The attribute values are stored in the attribute columns.
    1) Open the Order header screen.
    2) Click on the DFF and check the DFF name.
    3) Query the DFF name from the sysadmin Resp, to check the columns of attributes and the pertaining value sets.

  • How can I run two different vi's in same project which are accessing same global variable with out effecting the speed of the execution of both the vi's

    Hi
    I have build an Labview project with FPGA target .  I have configured an FPGA VI and an host Vi to acquire data and logged the data to a file and stored the latest data in a global variable simultanously. I have configured one more VI in the same project  to access the global variable.  I have build a dll to access both the VI as functions in LabWindows/CVI code.  My task in CVI is to update configured GUI with latest data periodically and run the  host VI continously for a long time and log the data to a file. GUI should update for every one second with latest data for this I am using the second VI in which I am accessing the global varibale in which the latest data has been stored in host VI.

    Duplicate Post (go here)

  • How to declare a global variable from a PL/SQL package

    Hi All,
    Using a global variable is a bad practise for all language. However, in my case, I have a PL/SQL package defines all constants, and I want to use them directly via SQL statement, for instance,
    PACKAGE my_const
    IS
         DEFAULT_ZIP_CODE CONSTANT VARCHAR2(5) := '00000';
    END;And I cannot referrence this variable from my select statement as
    SELECT my_const.DEFAULT_ZIP_CODE from dual;I have to create a function via my package, as,
    FUNCTION get_default_zip_code RETURN VARCHAR2
    IS
    BEGIN
         RETURN DEFAULT_ZIP_CODE;
    END;and
    SELECT my_const.get_default_zip_code from dual;I don't want to create functions to referrence the default varaibles. Does anyone have any clues?
    thanks
    Edited by: user4184769 on Jul 19, 2010 8:36 AM

    riedelme wrote:
    thanks for the info. Your scope explanation makes sense even though it is not intuitive to me. I think the usage of package variables should be supported by SQL (they're just values to be copied) Maybe look at it from another language's perspective. You want to use a global PL package variable in Java/C#/Delphi/VB/etc. How would you do it?
    None of these languages can crack open the data segment of a PL code unit, inspect the variables in it, and extract a value from it. Instead, it needs to be done as follows:
    Using sqlplus as the client illustrates how all these languages will need to do it:
    SQL> var value varchar2(20);
    SQL> begin
      2>     :value := SomePackage.someVar;
      3> end;
      4> /So why should SQL behave differently? It is not the same as the PL language. It is not a subset of the PL language. Yeah, PL/SQL blurs the line between these 2 languages making it very simple for us to mix their source code. But PL/SQL is SQL integrated with PL - not PL integrated with SQL. PL has tight hooks into SQL, creating cursors for you, defining bind variables, binding variables and doing the whole Oracle Call Interface bit for you.
    But SQL has no need for PL code, just as it has no need for Java code, or Delphi code or VB code. Yes, it is possible for it to call Java stored procs. As it is possible for it to call PL procs. But these are via the formal call interface of those languages - not via tight integration hooks that blur the languages and make SQL and Java, or SQL and PL, look like a single integrated source code unit.
    Thus SQL has the pretty much the same constraints in calling the PL language as other languages do. What SQL can do is use the PL engine's call interface and tell it "+execute this function and return the result of the function+".

  • Global Variable in entity beans

    Dear Friends,
    For example let us think that we have an entity bean for Customer.
    and we created an instance of that bean for customer A and then for customer B.
    So will the global variables in Customer bean be shared across Customer A and Customer B or will there be seperate instances for both Customers.
    Thanking You,
    Chamal.

    Your concepts seem to be a little messed up.
    For entity bean, remember the following:
    1. each object/instance of entity bean represents a record in a database
    2. when a client looks up an entity bean (typcially by using findByPrimaryKey method on home object), the record from database is searched and its values are stored in Entity Beans variables (this is probably what you mean by Global Variable. But thats an incorrect terminology in Java/J2EE. Class attribute is the correct word)
    3. In step 2, you fetched a record and that record is represented by a java object, which is nothing but entity bean.
    4. Now if you make changes to this java object, these changes will persist in the database. That is the essence of entity bean.
    5. If you use the home object's findByPrimaryKey method and look for the same record, no new object will be created. The 2 remote objects will point to the same entity bean on the server.
    6. If yo use the home object's findByPrimaryKey method and look for another record/customer, a new object will be created on the server. This new entity bean will map to the new record.
    Note taht the attribtues of CustomerA and customerB will never be shared.
    hope that helps

  • Word 2010 VBA - Global Variables in VBA and using them in VBA Code

    Hiya
    I need some help.  I have the following code that takes a word document, converts it to pdf and saves it to the local temp folder and attaches it to an email.  Up until now the filename for the file has been hard coded.
    I have now created a userform that allows the user to enter a filename for the document and I have created a global variable for the filename to be stored.
    What I want to be able to do is pick up this filename from the global variable and add it to filepath in the code.  At the moment it just saves the document as Mytitle which is what the variable is called.
    Here is my code, can I please have some help as I am a little lost, this is the first time I have created something so complicated!!
    Public Mytitle As String
    Private Sub CommandButton1_Click()
    ConvertandSave
    Createemailandattach
    End Sub
    Sub ConvertandSave()
    'converts to pdf and save locally using filename from userform
    ActiveDocument.ExportAsFixedFormat OutputFileName:="C:\temp\Mytitle.pdf", _
    ExportFormat:=wdExportFormatPDF, OpenAfterExport:=True, OptimizeFor:= _
    wdExportOptimizeForPrint, Range:=wdExportAllDocument, From:=1, To:=1, _
    Item:=wdExportDocumentContent, IncludeDocProps:=True, KeepIRM:=True, _
    CreateBookmarks:=wdExportCreateNoBookmarks, DocStructureTags:=True, _
    BitmapMissingFonts:=True, UseISO19005_1:=False
    End Sub
    Sub Createemailandattach()
    'creates email and attaches to the file
    Dim oOutlookApp As Outlook.Application
    Dim oItem As Outlook.Mailitem
    Dim MyFileName As String
    On Error GoTo SendCancelled
    MyFileName = "c:\temp\Mytitle.pdf"
    Set oOutlookApp = GetObject(, "Outlook.Application")
    If Err <> 0 Then
        Set oOutlookApp = CreateObject("Outlook.Application")
    End If
    Set oItem = oOutlookApp.CreateItem(ofMailitem)
    Set objRecip = oItem.Recipients.Add("   email address goes in here")
    obj.Type = olTo
    oItem.Display
    'oItem.Subject = "My Profile - "& UCase(LastName) & " " & FirstName
    oItem.Attachments.Add (MyFileName)
    Exit Sub
    SendCancelled
        MsgBox "This macro was cancelled"
    End Sub
    Any help here would be very much appreciated

    Assuming that you have other code to set the value of Mytitle: change all instances of "c:\temp\Mytitle.pdf" to
    "c:\temp\" & Mytitle & ".pdf"
    Regards, Hans Vogelaar (http://www.eileenslounge.com)

  • Using a global variable within a function

    Hi all,
    I'm trying to learn how to use global variables, but can't quite get it right:
    Im trying to use two buttons, named UpButton and DownButton to control one global variable, p1
    A text field, named "Value" displays p1.
    Here's my code:
    p1 = 0;
    ButtonClick("UpButton", p1, 100,"Value");
    ButtonClick("DownButton", p1,(-100),"Value");
    function ButtonClick(ButtonName,Var,Increment,TextToChange){
                        sym.$(ButtonName).click(function(){
                        Var = Var + Increment;
                        sym.$(TextToChange).html(Var);
    However, it seems to be treating p1 as two different variables.
    Here's a link to the page to show you what I mean, apologies but this link wont work in google chrome because I'm using dropbox as a server temporarily
    In other browsers you may need to click "Show all content" or similar to any security warnings...
    https://dl.dropboxusercontent.com/u/83693404/ButtonTest/buttons.html
    Here are the project files:
    https://app.box.com/s/0shocivto8fl295h62uq
    Any help greatly appreciated, sorry if this is a stupid question,
    Katherine

    Hi Katherine,
    However, it seems to be treating p1 as two different variables.
    Indeed, your code created two different variables in two different scopes (I guess it as to do with JavaScript closures, but do  not ask me more, I am still a bit foggy about that idiosyncrasy ).
    In JavaScript, a primitive parameter – this is the case here with p1, a Number value –, is passed by value. In other words, a copy of the value is made. Your code handles two copies of the value stored in p1.
    This contrasts with an object parameter, which is passed by reference (address in memory), without copy. Your code would work if Numbers were passed by reference : the two Var (p1) would then point to the same address.
    The intent behind your trial is a global variable.
    1) Let us be as simple as possible :
    Stage : document.compositionReady event handler
    p1 = 0;
    buttonClick = function( Increment)
      p1 += Increment;
      sym.$( "Value").html( p1);
    Stage : DownButton.click event handler
    buttonClick(-100);
    Stage : UpButton.click event handler
    buttonClick(100);
    Without being preceded by the var keyword the variables are global.
    So the Number variable p1 can be accessed inside function buttonClick.
    And the Function variable buttonClick as well, is accessible inside click event handlers, everything (function definition +function calls) being inside the same symbol (Stage).
    2) Now, suppose this is no longer the case : you want to access a variable from another symbol.
    We create a new GraySquare symbol, instantiated both in the DownButton symbol (instance name DownSquare) and in the UpButton symbol (instance name DownSquare).
    Stage : document.compositionReady event handler
    p1 = 0;
    sym.buttonClick = function( Increment)
      p1 += Increment;
      sym.$( "Value").html( p1);
    The sym. prefix is now necessary to make the variable (here a Function, but you would proceed exactly the same with a String, Number or Boolean) accessible in other symbols.
    DownButton symbol : DownSquare.click event handler
    sym.getComposition().getStage().buttonClick( -100);
    UpButton symbol : UpSquare.click event handler
    sym.getComposition().getStage().buttonClick( 100);
    From these other symbols, the sym.getComposition().getStage(). prefix is necessary to acces to our global variable (function).
    The two examples are downloadable here : https://app.box.com/s/6vkyiqk7i8zwlw0j1wk1
    Gil

  • Replacing 20 fixstatements by Global Variable - Problem 255 bytes length

    Hello,
    we have an issue in businessrules with setting the fix statement on 1 dimension:
    we currently use Fix (@RELATIVE("CBU_ALL",0) ) - on level 0 are approx. 3000 members - on medium level are 20 CBUs Seat and 20 CBUs Door
    we have approx. 20-30 similar businessrules - which either calculate on seat or door CBUs
    the requirement is to either calculate with a rule the 20 CBUs for Seats or the 20 CBUs for Doors
    as we currently do not fix properly on either Seat or Door CBUs, we calculate approx. 1500 empty members (empty, if fix in another dimension done correctly) - tests showed, that this doubles the time which would be needed.
    I know we could easily set 20 fixes in each business rule:
    @RELATIVE("CBU_BMW_Seat",0)
    ....20 more....
    @RELATIVE("CBU_Ford_Seat",0)
    (the fix above would then exclude the 1500 members, which are below:
    @RELATIVE("CBU_BMW_Doors",0)
    ....20 more....
    @RELATIVE("CBU_Ford_Doors",0)
    unfortunately, the number of CBUs/Customers is frequently renamed or some are added, so I can not afford to built these 20 fixstatements into 20 different businessrules and maintain them all the time.
    I thought of using UDAs or Attribute Values -
    but it seems not to be possible in a fixstatment to combine a relative or Children fixstatement with UDAs, which are set on the upper member ?
    I assume it works, if I classify all 3000 level 0 members with UDA or attribute SEATS or DOORS - but that's inefficient
    @RELATIVE("CBU_BMW_Seat",0) AND @UDA(CBU,"SEATS")
    @CHILDREN("CBU_BMW_Seat") AND @UDA(CBU,"SEATS")
    @Descendants("CBU_BMW_Seat") AND @UDA(CBU,"SEATS")
    @UDA(CBU,"SEATS")
    generally, it seems not to be allowed to combine Children or descendant fixes with any other relations or conditions ?
    @CHILDREN(@Match(CBU," Seat") ) (attempt to search for all children of all CBUs with Seat in its name)
    So the idea is to define 2 global variables:
    1 for Seats and 1 for Doors:
    [SEAT] includes then then: @children("CBU_BMW_Seat") ... 20 more @children("CBU_Ford_Seat")
    advantage would be, we can maintain the list of CBUs in 1 place
    my problem is: length of global variable is limited to 255 bytes - I need 800 to 900 digits to define the 20 CBUs
    having 8 global variables instead of 40 CBUs referenced in Fixstatements is not really an advantage
    even if I would rename the CBUs to just S1,S2,S3,S4 D1,D2,D3 (S for Seat, D for Door) (and use aliases in Planning and Reporting with full name to have the right meaning for the users), it does not fit into 1 variable: @children("S1"), @Children("S2"), ..... is simply too long (still 400 digits)
    also other attempts to make the statement shorter, failed:
    @children(@list("CBU_BMW_Seat","CBU_Ford_Seat",.....)) is not allowed
    is there any other idea of using global variables, makros, sequences ?
    is there a workaround to extend global variable limit ? we have release 9.3.1 - is this solved in future releases ?
    are there any other commands, which I can combine in clever way in fixstatements with
    @relative
    @children
    @descendants
    with things like @match @list ?
    (Generation and Level are no approrate criteria for Separating Seat and Doors, as the hierarchy is the same)
    please understand, that as we use this application for 5 years with a lot of historic data and it's a planning application with a lot of webforms and financial reports, and all the CBU members are stored members with calculated totals and access rights and setup data on upper members,
    I can not simply re-group the whole cbu structure and separate Seats and Doors just for calculation performance
    CBU dimension details is like this:
    Generation:
    1 CBU_ALL
    2 CBU_BMW
    3 CBU_BMW_Seat
    4 Product A
    4 Product B
    ..... hundreds more
    3 CBU_BMW_Door
    4 Product C
    4 Product D
    .... hundreds more
    2 CBU_Ford
    3 CBU_Ford_Seat
    4 Product E
    4 Product F
    .... hundreds more
    3 CBU_Ford_Doors
    4 Product G
    4 Product H
    .... hundreds more
    20 more CBUs with below 20 CBUs Seat and 20 CBUs Door

    How hard would it be to insert 2 children under CBU_All? Name them CBU_Seats and CBU_Doors, then group all the Seats and Doors under them.
    Then your calc could be @Relative(CBU_Doors, 0).
    I know it's not always easy or feasible to effect change to a hierarchy, but I just had the thought.
    Robert

  • How can I define global variable in user exit whic I can use anywhere.

    Hi all,
    How can I define global variable( Table ) which I can use when it come back to same user exit where I defined and stored some data.
    What I mean is I want to define 1 global table.
    In user exit when it comes I store some information. and again when it will come I will have that stored information so I can use it.
    Thanks a lot in advance.

    You can use EXPORT  TO MEMORY ID and IMPORT FROM MEMORY ID Statement for this.
    EXPORT T_ITAB FROM T_ITAB TO MEMORY ID 'ABC'.
    IMPORT T_ITAB TO T_ITAB FROM MEMORY ID 'ABC.'

  • GlobalContainer x Global Variable Java Section

    Guys,
    My requirement: I have a variable that'll be read from message header with DynamicConfiguration and will be used in several UDFs in a message mapping.
    Are there any problems in using either GlobalContainer object or Global Variable in Message Mapping Java Section for storing/recovering this variable?
    And in the case I use Java Sections, suppose I have the following:
    Global Variables
    String param = null;
    Initialization Section
    param = "value";
    Then, what do I need to use in Clean-up Section? Should I give it a null value or an empty string value? I mean, I can't understand the necessity of this section, since garbage collector would handle that variable (and supposing it will be valid only during this message mapping thread).
    Any thoughts?
    Thanks in advance,
    Henrique.

    Hey William,
    thank you for your input.
    Yeah, I thought that too, that clean-up section would be useful when I needed to use .close() methods on the open objects.
    And since java sections are newer, I think they are the prefered way too.
    Regards,
    Henrique.

Maybe you are looking for

  • Huge Syncing bug when iPad is almost full

    Hi, Just wanted to report I've just encountered a huge bug some minutes ago. My iPad1 16gb (4.3.3) was almost full, there were something like 491mb left. Tried to sync it via iTunes (10.3.1) which was unable to sync and import purchased apps cos it c

  • Payment Lot-Posting incomplete but posted a FICA document

    Hello, A payment lot was created with the status "Posting incomplete" and there were few items in the  "Not posted" list. When checked one of the accounts, the FICA document was posted for payment, but was NOT referring to the payment lot. The accoun

  • PLEASE HELP!!! (Adobe 8 Pro)

    On Adobe 8 Pro I have been spending countless hours trying to figure out how to add a "text caption" within a text field. What I mean is that for my work file I have designed a form with LiveCycle Designer and I did the final edits on Adobe but whate

  • Photoshop elements 10 Help

    Hello everyone, I have a few diagrams in TIFF format and after I do some modifications I need to convert it to Bitmap format. After converting from TIFF to BITMAP format, a lot of dots have popped up all over the page. I have been using eraser to era

  • IPTC and accents

    Hi all, It seems that Aperture daes'nt manage correctly accentuated characters in IPTC fields. My captions for exemple are in french and use "é" "è" "à" etc. They appear correctly as i stay in Aperture but i tried to export a file and read it's IPTC