Method / interface question

How do i write a method that takes an interface as an argument ?
void MethodName(interface InterfaceName){  }
void MethodName(InterfaceName){  }
????

Same as you would with any other Class:
public MyClass {
  public void myMethod(InterfaceName interfaceInstance) {
}

Similar Messages

  • Is there anyone using Java Methods interface of IREP in his application

    Hello everyone,
    Are you using Java Methods interface of IREP in your application?
    Nowadays I am trying to using Java Methods in my application. But I'm puzzled how to get the interface jar files that the Java Methods would import. It seems that Oracle doesn't provide such interface jar files for all Java Methods shipped in IREP. How do you do with this?
    If you have some experience about using Java Methods in application, hope to hear your voice. Thanks in advance.

    Hi friend,
    Thanks for you update.
    I'm referring to Java Methods that can be called directly by applications not Java Service Interface. These are two different kinds of IREP interfaces. In Oracle Integration Repository User's Guide, there aren't much guidance about how to use Java Methods.
    I appreciate you can help me further.

  • Java interface as method arg question.

    Hello,
    Imagine that I have the following two interfaces and their associated classes:
    AI, AC, FooI, FooC
    where AC and FooC implements the interfaces AI and AC respectively. Assume than that FooI has contains only the following method:
    public void doIt(AI arg);
    So far so good. Now assume that FooC attempts to implement the method in it's interface like so:
    public void doIt(AC arg);
    The java compiler complains thusly:
    C:\moment\javatest>javac AC.java AI.java FooC.java FooI.java
    FooC.java:1: FooC should be declared abstract; it does not define doIt(AI) in FooC
    public class FooC implements FooI
    I was surprised by this result. Since AC honors AIs contract, why is the compiler complaining. If someone could explain the reasoning behind the error, I'd really appreciate it. Thanks in advance.
    -exits

    AC may be an implementation of AI, but not every implementation of AI is AC.
    The FooI interface is essentially insisting that the method work on every implemenation of AI. If you create a method that works only on a particular subset of AIs, namely ACs, then you haven't really implemented the method as specified.

  • Question on Method interface

    Hi
    I've the following method def:
       METHODS : METH1 IMPORTING INPUT1 TYPE I  
                                                                  INPUT2 TYPE REF TO  CL_1.
    where CL_1 is the class withing where the method is defined.
    Question is, what is this kind of definition and whats the use in real time implementation?
    thkx
    P.S

    It can also be used in generic calls. Suppose we have vehicle class.
    CLASS lcl_vehicle DEFINITION.
       PUBLIC SECTION.
          METHODS: add_vehicle IMPORTING l_veh TYPE REF TO lcl_vehicle,
                            estimate_fuel.
          "table storing vehicles
          DATA: BEGIN OF it,
                       vehicle TYPE REF TO lcl_vehicle,
                     END OF it,
                     wa LIKE LINE OF it.
    ENDCLASS.
    CLASS lcl_vehicle IMPLEMENTATION.
        METHOD add_vehicle.
            wa-vehicle = l_veh.
            APPEND wa TO it.
        ENDMETHOD.
        METHOD estimate_fuel.
            LOOP at IT into WA.
               wa-vehicle->estimate_fuel( ).              "here we can call same method of different subclasses with different implementation
            ENDLOOP.
        ENDMETHOD.
    ENDCLASS.
    Now we create to subclasses.
    CLASS lcl_plane DEFINITION INHERITING FROM lcl_vehicle.
       PUBLIC SECTION.
          METHODS estimate_fuel REDEFINITION.
    ENDCLASS.
    CLASS lcl_ship DEFINITION INHERITING FROM lcl_vehicle.
       PUBLIC SECTION.
          METHODS estimate_fuel REDEFINITION.
    ENDCLASS.
    Two different vehicles will redefine an estimate_fuel method as each has to take different factors into account when tanking up.
    We would like to handle both plane and ship from one point. For this we add our new vehicles to the table of lcl_vehicle class.
    DATA: r_vehicle TYPE REF TO lcl_vehicle,
              r_plane    TYPE REF TO lcl_plane,
              r_ship      TYPE REF TO lcl_ship.
    CREATE OBJECT: r_vehicle, r_plane, r_ship.
    "add all vehicles to the table
    r_vehicle->add( r_plane ).
    r_vehicle->add( r_ship ).
    "Now we can perform generic call
    r_vehicle->estimate_fuel( ).  "this will call same method of two subclasses with different implementation, from one point
    It would be easy now to handle new vehicle
    CLASS lcl_motorbike DEFINITION INHERITING FROM lcl_vehicle.
       PUBLIC SECTION.
          METHODS estimate_fuel REDEFINITION.
    ENDCLASS.
    DATA: r_motorbike TYPE REF TO lcl_motobike.
    r_vehicle->add( r_motorbike ). "it is enough to add the vehicle, this already suits our model and appropriate method will be called for estimating fuel
    Regards
    Marcin
    Edited by: Marcin Pciak on Mar 23, 2009 10:17 PM

  • HR-PDC , Time Management Interface Question

    Hi,
    I am involved in a project that links Kronos Time Management system with SAP 4.6C . Since Kronos is certified for standard interface HR-PDC, we can use it for integration without patch-work.
    For more information, go to <a href="https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/sdn/developerareas/sdnservices/icc">this link</a> and on the right hand side, select Human Resources from Integration Scenarios -> Business Application Integration. Select HR-PDC from the list of interfaces available for HR.
    There are a few concerns though, the most important being related to transfer of HR mini-master data. It is mentioned in the interface documentation that SAP always sends complete master data for all employees and that deltas are not supported.
    Now, the customer has around 50,000 employees and sending data for each one of them every night doesn't seem to be a workable solution, especially when only 30-50 records change in a day. I understand that sending deltas can be accomplished through some tweaking, I am wondering why the standard interface won't support them, knowing the fact that all historical (delta) information is available from cluster PCL4.
    Although I understand that SAP themselves are in a better position to answer the question of why the interface is like that, I am asking if anyone experienced any short-comings with sending delta information. For example, perhaps the number of scenarios for which delta was to be transferred were too many and sending complete information was more suitable. So if anyone has had previous experience of working on HR-PDC, please shed some light on their experience.
    Secondly, is there a standard interface to record and send changes in Organization and Staffing (create, modifiy, delete) to a sub-system? I am talking in relation to t. code PPOME. Is HR-OCI the right interface for that???
    Thanks and regards
    Message was edited by: Shehryar Khan

    Hi,
    Thanks for the reply. It was quite helpful.
    It is fine to download time balances but downloading whole employee (mini)master data each day is a bit difficult to explain to stakeholders. Perhaps I may need to create my own driver program that populates data for modified employees only. Thoughts??? Is this the correct approach???
    As far as the second one is concerned, I am interested in downloading new/modified OM records like departments, jobs, positions, etc. It seems the same can be catered for by using HR-PDC through business object RCVPEVTREC, method receivePObject. I perhaps overlooked the interface specs.
    Thanks again and I may get back with more questions.
    Regards

  • Flexconnect Radius Server Overwrite interface Question

    Hello All,
    Can someone confirm/comment on the following:
    In a flexconnect scenario, for site 1, i would like to source the radius requests to a remote radius (at the flexconnect site 1).  as i can understand i need to enable the RAdius Server Overwrite interface option. Is that all?
     Also, for flexconnect sites X this can also be done per WLAN X configuration. 
    Is this correct?
    Thanks

    Hi pana,
    Answers below :
    Meaning that, even if i configure the Flexconnect groups with local authentication, then how does the Flexconnect ap reach the local radius?
    When you are working with local authentication, the AP will communicate with the local RADIUS Server using the local routing in the branch office without the 802.1X traffic being sending to the WLC......the AP will communicate directly to the local radius server using it IP address and the local routing. (This communication is transparent if you see from the WLC because the WLC will not intermediate the authentication between the client and RADIUS, who will intermediate is the AP. The WLC will receive informations when the AP is in connected mode about the client and the authentication method and etc after the user was authenticated).
    Example :
                                                                                                               RADIUS SERVER
    WLC ----SWITCH L3------ROUTER----(MPLS Link)-----ROUTER---SWITCH L3---AP
    The WLC continues managing the Access Point but will  not"talk" to the RADIUS Server, who will "talk" to the RADIUS Server is the AP in the branch office using the SWITCH L3 (Asumming that you have the RADIUS in one network and the AP in another network in the same branch office)
    Understand now ?
    As i can understand, in a local switching/local authentication scenario the Flexconnect ap can only map a WLAN to local VLAN( route-able network on the remote site) that serves for the users-data plane. Then in conjunction with the radius server override option, how can this FlexconnectAP send requests to the local radius? I can only suppose that it will do so using the users locally mapped VLAN/WLAN but i cant reference this anywhere. 
    The AP will only send the requests do the local radius only if you configure the FlexConnect Local Auth and FlexConnect Group. Enabling this option the AP will use it IP Address to communicate with RADIUS without the WLC intermedianting this communication.
    Without the FlexConnect Local Auth enable in the WLAN the AP will continue directing the 802.1X requests to the WLC and the WLC will send to the RADIUS Server and in this situation if you enabled the radius overwrite interface the WLC will try to reach the RADIUS Server using the WLAN interface and not the management the interface. (You do not need the radius overwrite interface option to work with Local Auth if you want to use the AP as a Authenticatior, you only use this interface if you want that the WLC with central authentication direct the 802.1X authentications to the RADIUS)
    One information about the VLAN/WLAN is really mapped statically but you can manipulate it using the RADIUS Atrributes, changing the VLANs from the USERs based in the AD Group and after the authentication. It can work in local auth scenario or central auth scenario.
    http://www.cisco.com/c/en/us/td/docs/solutions/Enterprise/Mobility/emob73dg/emob73/ch7_HREA.html#pgfId-1103070
    I hope it helps and if not helps i think i am not understanding the real question.

  • Interfaces questions

    I'm working through the tutorial and have a question about casting and interfaces.
    In the sample code in the tutorial, they cast other as RecanglePlus. This only makes partial sense to me. Given that the getArea() method would only work on basic rectangular/square shapes to begin with, do I still need to cast the 'other' object as a Rectangle? Presumably it would crash if I sent a circle object whether I cast the object or not.
    Thank you in advance for any clarification to this.
    public class RectanglePlus implements Relatable {
        // a method for computing the area of the rectangle
        public int getArea() {
         return width * height;
        // a method to implement Relatable
        public int isLargerThan(Relatable other) {
             RectanglePlus otherRect = (RectanglePlus)other;
             if (this.getArea() < otherRect.getArea())
                  return -1;
             else if (this.getArea() > otherRect.getArea())
                  return 1;
             else
                  return 0;              
    {code}

    robert_t wrote:
    I'm working through the tutorial and have a question about casting and interfaces.
    In the sample code in the tutorial, they cast other as RecanglePlus. This only makes partial sense to me. Given that the getArea() method would only work on basic rectangular/square shapes to begin with, do I still need to cast the 'other' object as a Rectangle? Presumably it would crash if I sent a circle object whether I cast the object or not.Yes, you would get a ClassCastException if you called that method with anything but a RectanglePlus. If the definition of an interface method depends on methods that aren't part of that interface, then chances are either both or none of those methods should be in the interface. If Area is something that a Relatable is defined to implement, then that getArea method should be part of Relatable. If not, then the interface isn't very useful.
    If you had another class Circle that implements Relatable, but doesn't have a getArea method, how would you ever use that common method to compare the two different types? You couldn't. If you make getArea an interface member, then any implementation of Relatable can return it's area, and you can leave the types as Relatable without casting to concrete types.

  • Implementing interfaces question

    I have a really vague question about interfaces....can't really figure out how this works...I know that interfaces only have method definitions and the implementing classes should define those methods.
    I am trying to use a DOM parser to parse an XML document. The org.w3c.dom package gives you a list of interfaces like Node, NodeList, Document etc to work on.
    Assume that i have the following code in my class:
    DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
    DocumentBuilder builder = factory.newDocumentBuilder();
    Document doc = builder.parse(invoiceXML);
    NodeList itemList = doc.GetElementsByTagName("item");
    Here is what I dont understand...doc is of type Document which is an interface. How can you call the method of an interface directly in the 4th line? I thought we are only supposed to call methods on the implementing class...the problem is I dont see an implementing class here...does the builder.parse(invoiceXML) return a Document interface or an object that implements the Document interface? If 'doc' is actually an object that implements the Document interface then it makes sense here...but then will all the methods be automatically implemented in the object created by the api?

    Here is what I dont understand...doc is of type Document which is an interface. Yes.
    How can you call the method of an interface directly in the 4th line? How? Just like that.
    I thought we are only supposed to call methods on the implementing class...Methods are applied to objects, not classes.
    the problem is I dont see an implementing class here...And you don't need to. Do you need to open up your DVD player and look inside in order to push "play"?
    does the builder.parse(invoiceXML) return a Document interface or an object that implements the Document interface? Methods don't return interfaces. They return references to objects (or primitive values).
    If 'doc' is actually an object that implements the Document interface then it makes sense here...Eureka!
    but then will all the methods be automatically implemented in the object created by the api?"Automatically" is not how to think about it. The Document interface was implemented by some class, the details of which aren't important. What's important is that if you have a reference to an object of type Document, you can apply Document methods to it, according to the API for Document.

  • WLS Users and Groups interface questions / observations

    I'm new to WLS, having just installed OBIEE 11g for the first time. There are some oddities in WLS around setting up Users that I'd like to ask about, to see if I'm just missing something, or if the interface really IS this bad. Please feel free to comment in any way, or to correct any statements that are erroneous. Here goes:
    1. The use of Previous and Next buttons instead of a vertical scroll bar for finding users and groups in their respective lists. What if you have several hundred users, and the one you want to modify starts with the letter 'Z'? That means clicking the Next button several dozen times. (Security Realms … myrealm … Users and Groups … Users) Not only is there no scroll bar, there's no search box either. The only way to get to a user near the end of the alphabetical listing is the Next button. Is that correct?
    2. After adding a new user, what's the next most logical thing to want to do? How about assigning that user to Groups? So why do I have to click Next several times to find that new user in the alphabetical list? I don't see a sortable 'Date Modified' field for the table of users, nor a link to the "Most Recently Added" user. Nor can I assign groups during the same action as creating the user. In the example in #1, I might have to click Next several dozen times to get to the user I just added. Is that correct?
    3. When creating a new User, immediately after clicking New, where is the most likely place that I'd want to go? How about the Name field? Right now, the cursor rests in some indeterminate location. I have to hit the Tab key 14 times, or move the mouse into the Name box and click it. The active cursor position does not default to the Name box when creating a new user. Is that correct?
    4. I don't see a 'Create Like' button for creating Users, so that existing group membership can be easily replicated. I'd like to be able to add a new employee by clicking to highlight an existing user from the same department, clicking a 'Create Like' button, then entering a new user name and password, with all group memberships assigned automatically based on the source user. The same could be said for replicating groups. I don't think that exists. Is that correct?
    5. I don't see a clean way to return to the User list on the page on which I clicked a user name. Imagine that I'm going through my entire list of users one at a time to set an attribute. I click on the user JSMITH and set the attribute. The only way to get back to JSMITH's page and select the next user list is to hit the browser's back button three times, or to click the Users and Groups breadcrumb at the top of the screen and use the Next link multiple times to find that page again. Is that correct?
    6. I don't see a way to bring up a Group and assign Users to it from a list. It appears that the only way to assign a User to a Group is to access a User profile and click Groups. If we're creating a new group that has 200 users selected from a list of 500 users, that could potentially represent somewhere between 5000 and 10000 mouse clicks. It would be much more efficient to be able to bring up a group, then select its members from a list of users. That does not appear to be possible. Is that correct?
    7. It also appears that when assigning groups for Users, the list of Available Parent Groups sorts the lowercase entries after all uppercase entries, so that groups that start with the letter 'a' fall after groups that start with 'Z'. That is not the case with the list of users. The User table uses a case-insensitive sort. Is that correct?
    8. When I want to delete more than one User, and the ones that I want to delete are on different pages, there appears to be no way to select those users from multiple pages at the same time. So, imagine that I have 500 users, and I want to delete two users, one of whom is listed on page 48, and the other on page 50. I would have to click the Next button 47 times to find the first user and delete it. At that point, the interface returns to page 1, and I have to click the Next button 49 times to reach the second user. Is that correct?

    Hi,
    Regarding your first question, you might want to press the "Customize this table" button, then select the maximum allowed amount of rows in "Number of rows displayed per page:" that would resolve some of the problems you're having with the interface. I do think this is not a great graphical tool, and there are some usability issues.
    Regarding the adding of users to groups, it seems the way you describe is the only way of doing it, however you could try using a script instead of the graphical console, the easiest way of making it is adding a user to a group while using the "Record" button on the top of the screen to get a wlst script to use as a model, then create a new script with all new users you want to add/modify.
    Regards,
    Franco.

  • Remote Interface question

    I have a remote Interface as follows.
    public interface AccessDataBaseI {
    List retrieveItems(Object id) throws ApplicationException;
    The ApplicationException extends RemoteException.
    public class ApplicationException extends RemoteException {
    public AppException () {}
    public AppException (String msg) {
    super(msg);
    I build compile the application and I dont have a problem .When I deploy it to the server I get the following error message .
    method retrieveItems(Object id) defined in the remote interface must include java.rmi.RemoteException in its throws clause.
    It includes the ApplicationException in its signature which extends RemoteException .
    Any ideas what could be wrong and how to over come this .
    I am using weblogic 8.1.4 .
    Thanks for your help.

    It's not a good idea to subclass RemoteException for your ApplicationException. RemoteException
    should be preserved for system level failures. I would recommend instead subclassing
    java.lang.Exception. If you're using the EJB 3.0 Remote business interface there is no longer
    a requirement to declare RemoteException on each method signature.
    --ken                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Java Interface Question.

    There are classes in the Java SDK, such as the Interface:
    org.w3c.dom.Document
    that have factory methods in them that carry out actual operations.
    But how can this be possible, because when I program an interface:
    public interface test {
    public void setString(String s);
    It will only compile thus, with no implementation on the method signatures?
    How do Java interfaces with factory methods to this?
    org.w3c.dom.Node is another one. Where does the functionality/method implementation
    come from?

    public interface MyInterface {
         public void method1();
    class MyImplementation implements MyInterface {
         public void method1(){
    public class MyFactory {
         public static MyInterface createMyInterface(){
              return new MyImplementation();
    public class Test{
               public static void main(String args[]){
                      MyInterface x=MyFactory.createMyInterface();
                      x..method1();
    }Now can you understand this? Assume all These classes are separate classes. This is not a problem with inner classes. Before make a reply, try to understand it or post a reply as saying it is not clear rather than posting this kind of post.

  • Method design question...and passing object as parameter to webserice

    I am new to webservice...one design question
    i am writing a webservice to check whether a user is valid user or not. The users are categorized as Member, Admin and Professional. For each user type I have to hit different data source to verify.
    I can get this user type as parameter. What is the best approach to define the method?
    Having one single method �isValidUser � and all the client web service can always call this method and provide user type or should I define method for each type like isValidMember, isValidAdmin ?
    One more thing...in future the requirement may change for professional to have more required field in that case the parameter need to have more attribute. But on client side not much change if I have a single isValidUser method...all they have to do is pass additional values
    isValidUser(String username, String usertype, String[] userAttributes){
    if usertype == member
    call member code
    else if usertype = professional
    call professional code
    else if usertype = admin
    call admin code
    else
    throw error
    or
    isValidMember(String username, String[] userAttributes){
    call member code
    One last question, can the parameter be passed as object in web service like USER object.

    First of all, here is my code
    CREATE OR REPLACE
    TYPE USERCONTEXT AS OBJECT
    user_login varchar2,
    user_id integer,
    CONSTRUCTOR FUNCTION USERCONTEXT (
    P_LOGIN IN INTEGER
    P_ID_ID IN INTEGER
    ) RETURN SELF AS RESULT
    Either your type wont be compiled or this is not the real code..

  • GW Interface Questions

    We are looking for direction regarding communicating with Groupwise 7 for the purpose of generating 'Tasks', 'Alerts' and E-mail messages to individuals and groups. It has been suggested that communicating with the Groupwise Gateway API or SOAP would allow us to do this. Is there documentation in regards to how to communicate with these interfaces? If so, where would we be able to obtain them.
    We are currently using GroupWise 7.01 on NetWare 6.5. The application or service we are looking to develop will most likely be run on the Linux platform.
    Thank you in advance.
    Robert

    First ofall, there aRE developer forums accessible via nntp.
    Second, "through a GW interface" has no meaning in any language or
    universe. If you mean "can I create tasks programmatically?" Yes, via
    SOAP, object api, or api gateway. I already commented on this.
    I'll mention two other APIs
    C3PO allows CLIENT-SIDE plugins (win32 only) (eg adding a menu to client
    )...TokenAPI allows interactive use of Client (Win32 only) (eg popping
    up the busy search interface)
    now....see below
    >>>
    >>>
    >
    > Thank you for the quick response. Currently we have an admin who does
    > this manually by placing tasks in each individual's task list as a
    > reminder on appeal due dates. We assumed that if it could be done
    > manually, we could automate this function.
    Of course. All things can be automated. At worst, you reverse engineer
    the code nad write your own. But that's not what you mean
    Is there no way to do this
    > through a GroupWise interface?... or should we be developing this
    > outside of GroupWise?
    >
    Already commented. Your statement is poorly and unclearly worded, so I'm
    ignoring it, after having added what I could.
    > Just to clarify, here are our requirements:
    > We need to be able to have a process that can create Tasks on
    > employee's task lists to alert them to various milestones in the
    > appeals process. For instance, 30, 15, and 5 days before letters are
    > due, certain people should receive a task from the system to complete
    > their work.
    >
    You can create a task programmatically. Of course the user has to accept
    the tasks, otherwise they only show in the inbox, but that's eactly like
    currently. SOAP and Object API
    > -Any replies generated to these tasks need to go back to humans (a
    > receipt notification of completion)
    Well, that's nice. You can set the notification options for the task
    before sending. SOAP and object api are again good options.
    The FROM address is not settable. It is set as whoever you log in as.
    Yes you log in as the sender. Either you supply the username, password
    or you use the "Trusted Application API" to access all mailboxes as a
    trusted user. The initial generation of the Trusted Key requires Win32,
    thenceforth Object API or SOAP.
    >
    > -Some recipients of these automated messages will need to be a mailing
    > list: we need to send alert messages to certain members or groups
    >
    Why do I care. Yes yes recipients. Groupwise supports recipients.
    Recipients are good because email travels from one place to another. Of
    course if these are internet users they just get the ical equiv of the
    task, which isn't quite as good.
    Seriously, whatever, programmatically this matters very little. I guess
    I should be happy you were complete.
    > -Different messages will be sent daily, potentially many messages
    > (10-20) sent on a given day.
    >
    Yes, yes. Of course you'll have to write said program and it will some
    how be configured as to this schedule. But that's easy.
    BTW 10-20 isnt many. 20000-100000 is many. GW laughs at your feeble
    10-20 messages (well assuming they aren't 1 million recips each).
    >
    >
    > Thank you again.
    You are welcome. Now, go to developer.novell.com/groupwise . Choose
    Object API (if win32 is acceptable, it's a bit easier, more mature, and
    faster), or SOAP (cross platform, becoming the flagship), download the
    NDK, and write the durn thing. More questions? NNTP the support forums,
    and you'll find the dev forums magically too.
    >
    > Robert
    >
    >

  • User Interface Questions

    I have already programmed some dialogs in JavaScript. I'm not using Script UI, although I've played around with Script UI a little bit. Now I'm getting a bit more advanced with some user interfaces and dialogs and have a few questions:
    1. Is it possible to create a "live updating" dialog similar to InDesign's Files > New > Document, where based on a menu selection of a preset, the dialog's editboxes change their values to reflect that menu selection?
    2. Can you program something like the Presets button in InDesign's New Document dialog where the user clicks "Save Preset", names it, and then the main dialog updates with the new preset the user just created.
    3. Script UI does not have measurement friendly boxes, does it? By that I mean that when you enter inches, mm or picas, the box will translate it into the current measurement type.
    4. I love the nudge option on the measurement editboxes. Can that be done via Script UI?
    Ideally my coding needs to work in both CS2 and CS3 and I code in JavaScript because that's what I know, but if the "live updating" stuff is possible in AppleScript or VBScript I'd still like to be aware that it can be done.
    While code examples of any of this are welcome, I mostly need to know what's possible, and any starting point you can offer will help (like the name of the control). That way I can start looking things up and figuring them out.
    Thanks in advance,
    Dan

    Thanks for the answers Bob. They are exactly as I thought, but wanted to make sure. It sucks that we have to recreate (via code), things that were given to us before Script UI. I know Script UI is more powerful in some ways (and hopefully sure will get more powerful with time) but loosing measurement boxes is a big bummer. They had so many nice built in features. I feel like I need to reinvent the wheel with Script UI.
    1. Do you have any example dialogs that you could post? I can often figure out how to get a lot of stuff done by looking over examples other people have created. Especially things where one feature interacts with another, but even just a dialog with menus, text, etc so I can check out how to layout the dialog. I have created one dialog with Script UI, but am not sure if I am doing it very efficiently and I couldn't find any Script UI stuff in InDesign's sample scripts.
    2. I suspect if I use Script UI I'll have to verify that only numbers are entered into the edit fields right? I need numerical values only for what I will be doing. Any thoughts on the best way to verify it's only a number in there? Can I do that live in the dialog before the user clicks OK? Argh, all these complications make me less than enthusiastic to go to Script UI, but I really would like to be able to have a live updating dialog.

  • Access Modifiers Effect on Static Method Hiding Question

    I am studying for my SCJP exam and have come across a question that I do not understand and have not yet found a satisfactory explanation.
    Given:
    package staticExtend;
    public class A{
         private String runNow(){
              return "High";
         static class B extends A{
              public String runNow(){
                   return "Low";
         public static void main(String args[]){
              A[] a=new B[]{new B(),new C()};
              for(A aa:a)
                   System.out.print(aa.runNow()+" ");
    class C extends A.B{
         public String runNow(){
              return "Out";
    }The output is "High High". The explanation in the sample exam from ExamLab was that because the runNow() method in A was private that only an explicit cast to the B class would invoke the runNow() method in B. I have verified that that is the case, but am not clear on how the runNow() method being declared static in B and how the private access modifier in A results in this behaviour.
    Any additional explanation would be greatly appreciated.
    Thanks in advance.
    -- Ryan

    Ryan_Chapin wrote:
    OK, so since runNow() in A is private the compiler determines that regardless of the available methods in any of it's sub classes that since we declared the original array reference as "A" that it will invoke the runNow() in A. It's also due to the fact that the invocation came from within A. You would have gotten a compile time error if you tried to place the code in the main method in another class.
    >
    My mistake about the second part that you mention. You are correct. runNow() in B is NOT static, but the class is static. I guess that was the red herring in this question I don't see how that is related. I actually think that the "red herring" was what I described above. The fact that the code was placed in A, and that private methods can't be overridden.
    and the fact that the class itself is static has nothing to do with the behaviour that is being illustrated. Is that correct?Correct

Maybe you are looking for

  • Hyperion EPM 11.1.2 Planning Configuration Issue

    Hello, I am experiencing a bit of a problem when attempting to configure Hyperion EPM 11.1.2. Envrionment: Windows Server 2003 R2 64-bit, Oracle 11g Issue: Configuration abruptly fails during after the configure database screen for additional EPM pro

  • P2 card

    I've just ordered a new MacBook Pro, but I don't know how to transfer video from my Panasonic P2 cards to the new laptop that uses express cards. Does anyone know of a reasonably priced reader, or some other solution? Thanks

  • How to solve no bass problem on Satellite A110-230?

    I have read about other users having some problems with sound. There is no bass when I connect my stereo system. So I used the search and found a solution. Renamed two files! The sound quality is better now but incomparable with other laptops I tried

  • Driver for 3csoho100b-tx LAN card

    I searching desperately for a driver for my 3com 3csoho100b-tx LAN card, I have searched Google and several forums but there doesn�t seem to be one available. I know on Linux I can use the tulip driver is there anything similar on Solaris 10??

  • Change status on a SC as an administrator

    Hi, Im running on SRM 6.0 and I would like to change status on a SC from staus completed to cancelled, no follow-on-doc has been created. Can I do that as an administrator? Best Regards Jonas