Question about running classes as standalone apps

I have figured out that I can run a java application as a standalone application by including javaw.exe in my program and then creating a shortcut to that javaw.exe. For instance the target for the shortcut would be: "C:\Win\ChatProg\javaw.exe ChatFrame"
Now my problem is that I can't figure out how to make the target point to the folder the program is in, not "C:\Win\ChatProg\" I want to do something like "CODEBASE%\javaw.exe ChatFrame" is there any way to do that?
Thanks!

Right-click the shortcut and select "Properties". Put whatever you want to be the current directory when the application runs into the "Start In" box.

Similar Messages

  • A question about Object Class

    I got a question about Object class in AS3 recently.
    I typed some testing codes as following:
    var cls:Class = Object;
    var cst:* = Object.prototype.constructor;
    trace( cls === cst); // true
    so cls & cst are the same thing ( the Object ).
    var obj:Object = new Object();
    var cst2:* = obj.constructor.constructor;
    var cst3:* = obj.constructor.constructor.c.constructor;
    var cst5:* = Object.prototype.constructoronstructor;
    var cst4:* = Object.prototype.constructor.constructor.constructor;
    var cst6:* = cls.constructor;
    trace(cst2 === cst3 && cst3 === cst4 && cst4 === cst5 && cst5 === cst6); //true
    trace( cst == cst2) // false
    I debugged into these codes and found that cst & cst2 had the same content but not the same object,
    so why cst & cst2 don't point to the same object?
    Also, I can create an object by
    " var obj:Object = new cst();"
    but
    " var obj:Object = new cst2();"
    throws an exception said that cst2 is not a constructor.
    Anyone can help? many thanks!

    I used "describeType" and found that "cst2" is actually "Class" class.
    So,
    trace(cst2 === Class); // true
    That's what I want to know, Thank you.

  • Question about inner class - help please

    hi all
    i have a question about the inner class. i need to create some kind of object inside a process class. the reason for the creation of object is because i need to get some values from database and store them in an array:
    name, value, indexNum, flag
    i need to create an array of objects to hold those values and do some process in the process class. the object is only for the process class that contains it. i am not really certain how to create this inner class. i tried it with the following:
    public class process{
    class MyObject{}
    List l = new ArrayList();
    l.add(new MyObject(....));
    or should i create the object as static? what is the benifit of creating this way or static way? thanks for you help.

    for this case, i do need to create a new instance of
    this MyObject each time the process is running with a
    new message - xml. but i will be dealing with the case
    where i will need a static object to hold some
    property values for all the instances. so i suppose i
    will be using static inner class for that case.The two situations are not the same. You know the difference between instance variables and static variables, of course (although you make the usual sloppy error and call them static objects). But the meaning of "static" in the definition of an inner class is this: if you don't declare an inner class static, then an instance of that inner class must belong to an instance of its containing class. If you do declare the inner class static, then an instance of the inner class can exist on its own without any corresponding instance of the containing class. Obviously this has nothing to do with the meaning of "static" with respect to variables.

  • Questions about using the Voice Memos app

    I'm currently an Android user, but will be getting an iPhone 6 soon. My most used app is the voice memos app on my Android phone. I have a couple questions about the iPhone's built-in voice memos app.
    -Am I able to transfer my voice memos from my Android phone to my iPhone, so my recordings from my Android app will show up in the iPhone's voice memos app?
    -When exporting voice memos from the iPhone to computer, are recordings in MP3 format? If not, what format are they in?
    -In your opinion, how is the recording quality of the voice memos app?

    You cannot import your Android voice memos to your iPhone's voice memo app.  You might be able to play the Android memos and have the iPhone pick up the audio and record it.
    Here is the writeup about sending voice memos from the iPhone to your computer (from the iPhone User Guide):
    App quality is excellent.

  • Question about abstract classes and instances

    I have just read about abstract classes and have learned that they cannot be instantiated.
    I am doing some exercises and have done a class named "Person" and an abstract class named "Animal".
    I want to create a method in "Person" that makes it possible to set more animals to Person objects.
    So I wrote this method in class Person and compiled it and did not get any errors, but will this work later when I run the main-method?
    public void addAnimal(Animal newAnimal)
         animal.add(newAnimal);
    }Is newAnimal not an instance?

    Roxxor wrote:
    Ok, but why is it necessary with constructors in abstract classes if we don�t use them (because what I have understand, constructors are used to create objects)?Constructors don't create objects. The new operator creates objects. An object's c'tor is invoked after the object has already been created. The c'tors job is to initialize the newly-created object to a valid state. Whenever a child object is created, the parent's c'tor is run before the child's c'tor, so that by the time we're inside the child's c'tor, setting up the child's state, we know that the parent (or rather the "parent part" of the object we're initializing) is in a valid state.
    Constructor rules:
    1) Every class has at least one ctor.
    1.1) If you do not define an explicit constructor for your class, the compiler provides a implicit constructor that takes no args and simply calls super().
    1.2) If you do define one or more explicit constructors, regardless of whether they take args, then the compiler no longer provides the implicit no-arg ctor. In this case, you must explicitly define a public MyClass() {...} if you want one.
    1.3) Constructors are not inherited.
    2) The first statement in the body of any ctor is either a call to a superclass ctor super(...) or a call to another ctor of this class this(...) 2.1) If you do not explicitly put a call to super(...) or this(...) as the first statement in a ctor that you define, then the compiler implicitly inserts a call to super's no-arg ctor super() as the first call. The implicitly called ctor is always super's no-arg ctor, regardless of whether the currently running ctor takes args.
    2.2) There is always exactly one call to either super(...) or this(...) in each constructor, and it is always the first call. You can't put in more than one, and if you put one in, the compiler's implicitly provided one is removed.

  • Question about running EverQuest on a Boot Camp MacMini

    Hey all,
    I'm trying to get EverQuest working on my MacMini running Windows 7 via Boot Camp. Browsing through the archives of the internet, I've found many posts from 2007-2010 of people having success with this on a MacBook Pro (a few posts of which I found in these community archives), and I'm 99% certain that my MacMini hardware is more than sufficient. Anyway, I haven't even got to loading the game yet so performance my question isn't about performance.
    My issue is that I'm trying to run the EverQuest LaunchPad to start patching the game, and it won't connect right from the outset. I've followed all of SoE's EQ LaunchPad Troubleshooting tips (here: http://help.soe.com/app/answers/detail/a_id/29017 ) and I've also gone in to my router settings and opened/forwarded all of the necessary EQ ports to this computer's IP address. I was hoping that would do it but no luck.
    I also contacted the SOE Support staff and they were categorically unhelpful as usual. I used to play EQ a decade ago and I wasn't surprised to see that their customer service hasn't changed one bit. Well, here's to hoping that the Mac community is much more positive and helpful than SOE Support.
    Has anyone experienced similar problems getting EverQuest to run on a Windows Boot Camp machine like this? How did people get their LaunchPad client to connect? I'm hoping there's some really dumb, obvious fix that I'm missing here because it really does seem like many have gotten this to work successfully and I'm a bit stumped at the moment..
    Any advice would be greatly appreciated. Thanks!

    the hardware of macs today and windows computer is pretty much the same
    so when one use bootcamp it's really just a bootloaded which collects the windows partition from the harddisk and then let it take over and apart from one having to install the apple drivers and software to get it running well
    it's the same as any windows computer
    I do all my my gaming on windows on my imac and face no different challenges then I did when I had a windows computer really
    so If I were you I would broaden my googling for solutions not just to include bootcamp but all windows issues with newer windows versions and everquest could as easy be a issue there with newer video card drivers and the likes

  • Question about handing classes in Objective-C

    Greetings -- I'm pretty new to Objective-C. I do have a few apps out in the app store, but they were simple one-form apps where I was able to dump everything into the main class and be happy with it.
    This new project I'm working on, is huge in comparison. Over 25 views, accessible through TableView driven menus.
    I was able to get all of the menus working, each launching a separate view NIB file (so far, just a label to show me that it's done, but I got that part working.)
    Now what I'm trying to do, is add a "click" sound when a row is selected. But I'm wanting to do this in a separate class, so each .m file can instantiate it's own version of the logic instead of having the same code 29 times.
    So, this is what I've done:
    Click.h
    #import <Foundation/Foundation.h>
    #import <AudioToolbox/AudioToolbox.h>
    @interface Click : NSObject
    SystemSoundID soundID;
    -(void) playClick;
    @end
    Click.m
    #import "Click.h"
    @implementation Click
    -(id) init
    self = [super init];
    NSString *path = [[NSBundle mainBundle] pathForResource:@"click" ofType:@"wav"];
    AudioServicesCreateSystemSoundID((CFURLRef)[NSURL fileURLWithPath:path], &soundID);
    return self;
    -(void) playClick
    AudioServicesPlaySystemSound (soundID);
    @end
    RootViewController.h
    #import <UIKit/UIKit.h>
    #import "Click.h"
    @interface RootViewController : UITableViewController <UITableViewDelegate, UITableViewDataSource>
    NSArray *controllers;
    Click *clicker;
    @property (nonatomic, retain) NSArray *controllers;
    @property (nonatomic, retain) Click *clicker;
    @end
    RootViewController.m
    #import "RootViewController.h"
    @implementation RootViewController
    @synthesize controllers, clicker;
    - (void)viewDidLoad
    Click *newClicker = [[Click alloc] init];
    clicker = newClicker;
    [newClicker release];
    self.title = @"Main Menu";
    - (void)dealloc {
    [controllers release];
    [clicker release];
    [super dealloc];
    #pragma mark Table View Delegate Methods
    -(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
    [clicker playClick];
    I cut out the code pieces regarding the TableView that I know works, and tried showing only the parts that I've added to make the sound.
    What I've tried, is when the RootViewController is created, it has a SystemSoundID type variable defined with it named clicker. Then as part of "viewDidLoad", instantiate an instance of the class and have it automatically populate the variable "soundID". Then during "didSelectRowAtIndexPath", I want the "playClick" method of "clicker" to be run, but at this point the app seems to get caught in some sort of perma-loop, and I have to "STOP"/"Home" out of it.
    I'm hoping the problem is my rookie-status at using Objective-C objects, and the solution jumps out at you veterans, and then whatever problem I am having won't be duplicated when I create additional classes that I'd want to merge into my ViewController logic.
    Hope I've made everything clear. If anyone has questions, I'll be checking for replies
    Thanks.

    Dragon's Nest wrote:
    Is it preferred to init a copy and assign it like you did above?
    Yes, it's an accepted pattern which you'll see in most of the sample apps. Asnor's code works just as well in this case, and it might always work for you if you stick to that same pattern. However if you were working on a team and everyone else used the more common pattern it might cause a problem. For example, this code would cause a memory leak:
    @property (nonatomic, retain) Click *clicker; // interface
    self.clicker = [[Click alloc] init]; // implementation
    The above is the flip side of your original code. In this case, because we're not releasing the newly alloced object, its retain count is +2 after the setter retains it.
    There are other advantages to the accepted pattern. Suppose you weren't assigning the new object to an ivar but only using the object in that one block of code. Should you then release it? Yes. Will you remember? Well, if you're using the pattern, you'll always release it. If you always release the local pointer regardless of whether it gets retained elsewhere, you're much less likely to have a memory leak. How bout the case where you return the pointer (i.e. alloc an object and return it's address from that method)? In that case you just autorelease it. So whoever called the method needs to retain the returned object if it needs to be used after the current event cycle.
    Either way, immediate release or autorelease, you're always releasing an alloced object in the same block of code.
    Memory management can easily get out of control without following consistent patterns. Alloc->retainBySetter->release is the accepted pattern for Cocoa. Your original code meant to use the correct pattern, but you just forgot that clicker=object isn't the same as self.clicker=object because the latter retains the object. Once you've consistently used the correct pattern for awhile, you'll almost never make that mistake.
    Also, is there any difference in calling it in the following two ways:
    @property (nonatomic, retain) Click *clicker; // <-- must be considered to answer this question
    @synthesize clicker;
    [clicker playClick];
    [self.clicker playClick];
    In the above case there's no difference since the getter synthesized for that property declaration will simply return the value of the ivar (i.e. the address of the retained Clicker object). But in the general case, there certainly could be a difference. If the property was atomic, for example, the results could be different. Of course there will definitely be a difference if you wrote a custom getter that did something more than the default.
    Is there a rule or convention re when to use the getter and when to use the ivar directly? Not that I know of. I think you just need to be aware of what the getter does when deciding whether to use the dot notation. This is a point you might want to research a little more, though. Maybe someone here with more experience in Obj-C or Cocoa will comment.
    In fact a few of the experts in this forum advise against ever using dot notation. They feel it was invented to crash newbie programs. If you never use dot notation the difference between these two lines is much easier to see:
    clicker = newClicker;
    [self setClicker:newClicker];
    But once again, if you stick to the same pattern all the time, it's much harder to make a mistake.
    - Ray

  • Question about "run application once" semantics...

    Hi to anyone still out there. We're still using ZfD 3.0SP1a with the
    latest NAL patch (10.4.2002). Things basically are working but we're
    redoing our software distribution strategy to try and streamline things
    and squeeze a bit more life out of the platform. As part of the process, I
    moved away from force run MSI installs by user for basic stuff to force
    runs which call msiexec /i some.msi (or setup or whatever...) and
    associating these to OUs. I was planning to use the app version number to
    force redistribution whenever I put up newer MSIs or installer files. In
    testing, I noticed that msiexec was running on each login for each package
    and that wasn't what I wanted. I want the installers to fire off once,
    then again whenever I bump the version number. So I checked off "Run
    application once". Now the apps run only once but do not redistribute when
    I up the version number. If I use nlist to query eDir, I can see the
    attribute "zenappDisconnectedVersionNumber" has been incremented in the
    directory but looking at HKLMSoftwareNetWareNAL1.0Distribute*, the version
    number for that app never moves and the software isn't redistributed. The
    apps are all set to "wait on force run".
    Am I misunderstanding the use of this attribute? I suppose I could leave
    "run application once" off and set up some registry flags to control
    distribution or even just let them run on each login but I want to do this
    in the cleanest fashion. Any suggestion about what I might be doing wrong
    or how to work around/troubleshoot this issue? Thanks in advance!
    Michael

    Thanks, guys. I have a follow up question/issue related to this
    environment. I am pushing out a handful of apps associated with
    workstations via OUs (force runs which call msiexec or a setup). I've
    tested this a hundred or more times in my own OU but in several other OUs,
    I've now run into this issue when NAL kicks off the first app install. I
    get a WMRUNDLL.EXE error and no software distribution occurs. The text of
    the Dr Watson error is:
    The application, WMRUNDLL.exe, generated an application error The error
    occurred on 11/07/2007 @ 12:54:26.495 The exception generated was c0000005
    at address 004AED14 (NWAPPCreateFullObjectName)
    In setting up a few machines today, the first ran fine, the next 3 got
    this error. I've synched up everything in PUBLIC across all servers; all
    NAL related files that I'm aware of (that show via NAL's "more" button)
    are from the last update for ZfD 3, dated 10-04.2002.
    I did some searching and the little I was able to find seemed to point at
    a particular version of wsreg.dll. Wasn't able to find any particulars
    though. Fwiw, wsreg32.exe and wsreg.dll in PUBLIC were dated 6.26.2001. I
    swapped in a wsreg.dll from 10.22.2002 which I believe was part of the
    49SP2 client. That apparently hasn't helped. Worst of all, it seems
    intermittent or arbitrary - I can't really see what's different between
    the environment I'm currently in that is experiencing the error and the
    one in which it's working. It's the exact same base image, exact same
    PUBLIC dir... the only difference is that it's not my home OU. I checked
    workstation policies in the other OU and they appear to be the same as in
    mine.
    I thought I was past this as the PUBLIC sync seemed to clear things up at
    another location but now I'm seeing it again. Have you seen this before?
    Any suggestions? Thanks a lot!

  • Questions about Adobe Muse CC single-app membership.

    When speaking to adobe customer service reps about Adobe Muse I feel like their taking me around in circles. My annual membership to the current Adobe Muse is going to expire in June. So before I sign on for another year I had some basic questions that seem to be baffling the adobe reps. one rep called Travis just hung up on me.
    My questions;
    With an Adobe Muse CC single-app membership.
    Can I host a site on Business Catalyst for free?
    The rep said I have to purchase Business Catalyst separately from Adobe Muse
    This adobe page says, “An Adobe Muse CC one-year single-app membership includes hosting for one webBasics site
    (http://www.adobe.com/au/products/muse/faq.edu.html)
    How much space do I get on www.creativecloud.comwith a single-app membership?
    The rep said I get 20GB when Adobe Muse becomes Adobe Muse CC in June
    I currently have Adobe Muse and I have 20GB of space on creative cloud.
    This adobe page says I get 10 GB (http://www.adobe.com/au/products/muse/faq.edu.html)
    This adobe page says I get 20 GB (http://www.adobe.com/au/products/muse/features.edu.html)
    Can someone pleas answer these questions!

    With an Adobe Muse subscription, you get BC website hosting for 1 webBasics site. With a subscription to the creative cloud, hosting for 5 webBasics sites are included.
    Single app subscriptions get 20GB of storage space on creative cloud.
    I'll try to get that first link updated with the correct info.

  • (newbie) Question about replacing .class files and web.xml file

    I'm new to servlets and I have two quick questions...
    Do I absolutely need a web.xml file to define all my servlets, or can I simply place .class files into the WEB-INF directory and expect them to run?
    If my application server (for example Tomcat) is running and I replace a servlet .class file, do I need to restart the server for the new .class file to take effect?
    ...or are both of these questions specific to the application server I'm using?

    Hi,
    From an article I read:
    With Tomcat 3.x, by default servlet container was set up to allow invoking a servet through a common mapping under the /servlet/ directory.
    A servlet could be accessed by simply using an url like this one:
    http://[domain]:[port]/[context]/servlet/[servlet full qualified name].
    The mapping was set inside the web application descriptor (web.xml), located under $TOMCAT_HOME/conf.
    With Tomcat 4.x the Jakarta developers have decided to stop allowing this by default. The <servlet-mapping> tag that sets this mapping up, has been commented inside the default web application descriptor (web.xml), located under $CATALINA_HOME/conf:
    <!-- The mapping for the invoker servlet -->
    <!--
    <servlet-mapping>
    <servlet-name>invoker</servlet-name>
    <url-pattern>/servlet/*</url-pattern>
    </servlet-mapping>
    -->
    A developer can simply map all the servlet inside the web application descriptor of its own web application (that is highly suggested), or simply uncomment that mapping (that is highly discouraged).
    It is important to notice that the /servlet/ isn't part of Servlet 2.3 specifications so there are no guarantee that the container will support that. So, if the developer decides to uncomment that mapping, the application will loose portabiliy.
    And declangallagher, I will use caution in future :-)

  • Question about running explain plan

    I tried to run explain plan for a simple query, just to familiarize myself with how to do it. (I have another query that's taking a long time, and I've never run explain plan before). I got an error, googled it, and discovered I had to run the file at @%ORACLE_HOME%\rdbms\admin\utlxplan.sql first, to create the Plan_Table. Well, I tried to run that file and I get the error that I don't have priveleges on the tablespace. This really doesn't surprise me, as my access is read-only. Is there any way around this? I don't know a whole lot about databases, so forgive me if these following questions are dumb, but...
    1) is that file basically trying to create a table (called Plan_Table) within the schema I'm in (the only schema I have access to)?
    2) can my company's DBA run that file for me to create the Plan_Table?

    What version of the database are you on?
    You can get run-time execution plans from V$SQL_PLAN. You will need permission to read the V$ views. First find your query in V$SQL_PLAN (you can do a text search; putting a comment in like '--my_query' can help), then join to V$SQL_PLAN to find the query plan that that query used - join by the ADDRESS and HASH_VALUE columns.
    Otherwise, see if you can get insert/update/delete access on just that one table when your DBA creates it
    Good luck.

  • Question about a Class loading error

    how can we obtain to reduce the size of classes throughout run time as the source code of my project alone is about 8 MB and this is too heavy for a me program.
    so anybody has any suggestions?

    I see thanks.
    Did you consider keeping that data outside of device (at some web server)? That way, MIDlet would be installed without it and later would download the data from web. Download, in turn, can be done either every time it is needed, or once at MIDlet first launch - in the latter case, downloaded data could be stored in rms for next time it is needed.
    Another idea that comes to mind is to keep data in "auxiliary" MIDlet(s) in different suite(s). That way, again, "main" MIDlet would be installed without it but there will be need to install "auxiliary" MIDlet suites with data. In order to provide data access for "main" MIDlet in other suite, the auxiliary MIDlet would need to run and store the data in a shared-access record store - that is, in store created with [AUTHMODE_ANY access parameter|http://java.sun.com/javame/reference/apis/jsr118/javax/microedition/rms/RecordStore.html#AUTHMODE_ANY].

  • Question about running a servelt using HTML form.

    Hi, Im new to Servlets , I have created a servelt with this code :
    package oracle.servlets;
    import java.io.IOException;
    import java.io.PrintWriter;
    import java.sql.*;
    import javax.servlet.*;
    import javax.servlet.http.*;
    public class LoginServlet extends HttpServlet {
        private static final String CONTENT_TYPE = "text/html; charset=windows-1252";
        private static final String DB_URL = "jdbc:oracle:thin:@localhost:1521:ahmaddb";
        private static final String DB_USERNAME = "fundinfo";
        private static final String DB_PASSWORD = "tadapps";
        private static Connection con;
        private String pass;
        private String name;
    /*init() : invoked by the servlet engine before the servicing of client requests
    - Can be used to retrieve initialization parameters
    – Takes a ServletConfig object as a parameter
    – Is invoked when the servlet instance is created
    – Is useful for obtaining database connections from a connection pool*/
        public void init(ServletConfig config) throws ServletException {
            super.init(config);
            //config.getInitParameter(arg0);
        public void doGet(HttpServletRequest request,
                          HttpServletResponse response) throws ServletException,
                                                               IOException {
    response.setContentType(CONTENT_TYPE);
            //PrintWriter : Print formatted representations of objects to a text-output stream.
            //getWriter() : Returns a PrintWriter object that can send character text to the client.
            PrintWriter out = response.getWriter();
            out.println("<html>");
            out.println("<head><title>My First Servlet</title></head>");
            out.println("<body>");
            out.println("<p>The servlet has received a GET. This is the reply.</p>");
            out.println("</body></html>");
            out.close();
        public void doPost(HttpServletRequest request,
                           HttpServletResponse response) throws ServletException,
                                                                IOException {
            response.setContentType(CONTENT_TYPE);
            PrintWriter out = response.getWriter();
            name = request.getParameter("user_name");
            pass = request.getParameter("user_password");
            boolean result = verifyPassword(name, pass);
            out.println("<html>");
            out.println("<head><title>LoginServlet</title></head>");
            out.println("<body>");
            if (result == true){
            out.println ("Hello " + name + ": Your login module is working great!");
            else{
            out.println ("Invalid user name or password");
            out.println ("</body></html>");
            out.close();
            // out.println("<p>The servlet has received a POST. This is the reply.</p>");
            //out.println("</body></html>");
            //out.close();
        public void configureConnection() throws SQLException {
        try{
        Class.forName("oracle.jdbc.OracleDriver");
        con = DriverManager.getConnection(DB_URL, DB_USERNAME,DB_PASSWORD);
        con.setAutoCommit(true);
        catch (Exception e){
        System.out.println("Connection failed: " +e.toString());
        public Connection getConnection() throws SQLException
        configureConnection();
        return con;
        protected boolean verifyPassword(String theuser, String password) {
        String originalPassword = null;
        try {
        con = getConnection();
        Statement stmt = con.createStatement();
        stmt.executeQuery("select password from login where uname='"+theuser+"'");
        ResultSet rs = stmt.getResultSet();
        if(rs.next())
        //>>
        originalPassword = rs.getString(1);
        stmt.close();
        if(originalPassword.equals(password)) {
        return true;
        else {
        return false;
        catch (Exception e){
        System.out.println("Exception in verifyPassword()="+e.toString());
        return false;
    }and created an HTML form to target this servlet
    <form action="/loginservlet" method="post">,
    when I enter the the credintials I get this output in the webpage :
    Error 404--Not Found
    From RFC 2068 Hypertext Transfer Protocol -- HTTP/1.1:
    10.4.5 404 Not Found
    The server has not found anything matching the Request-URI. No indication is given of whether the condition is temporary or permanent.
    If the server does not wish to make this information available to the client, the status code 403 (Forbidden) can be used instead. The 410 (Gone) status code SHOULD be used if the server knows, through some internally configurable mechanism, that an old resource is permanently unavailable and has no forwarding address.

    Thanks , yes it is added to the web.xml
    <?xml version = '1.0' encoding = 'windows-1252'?>
    <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" version="2.5" xmlns="http://java.sun.com/xml/ns/javaee">
        <description>Empty web.xml file for Web Application</description>
        <servlet>
            <servlet-name>LoginServlet</servlet-name>
            <servlet-class>oracle.servlets.LoginServlet</servlet-class>
        </servlet>
        <servlet-mapping>
            <servlet-name>LoginServlet</servlet-name>
            <url-pattern>/loginservlet</url-pattern>
        </servlet-mapping>
        <session-config>
            <session-timeout>35</session-timeout>
        </session-config>
        <mime-mapping>
            <extension>html</extension>
            <mime-type>text/html</mime-type>
        </mime-mapping>
        <mime-mapping>
            <extension>txt</extension>
            <mime-type>text/plain</mime-type>
        </mime-mapping>
    </web-app>Anymore suggestions?

  • A question about backend of creating the app with Xcode

    Hi,
    I'm a new iphone developer who just started to learn how to create iphone apps.
    I just started to learn about view-based applications.
    When I select view-based applications, XCode will automatically generate some files for me.
    For example, if a create a new project called "A", XCode will generate files like "AViewController.m", "AAppDelegate.m", and "main.m".
    but I don't see anywhere in those files where it's actually creating the instance of "AViewController" or "AAppDelegate".
    So at where and at which file are the instances of "AViewController" and "AAppDelegate" created?
    Also where is the instance of the main application created?(not A.app if you know what I mean)

    I hope I can add to the correct answer posted by J D McIninch since the solution to this thread might provide a good example of how xib objects work--i.e. what I tried to explain in your [previous thread|http://discussions.apple.com/message.jspa?messageID=11479911#11479911].
    Daviiidddd wrote:
    So at where and at which file are the instances of "AViewController" and "AAppDelegate" created?
    Open MainWindow.xib and make sure the xib window is visible by selecting Document from the Windows menu. You should see a solid orange cube labeled "A App Delegate", and a circular icon labeled "A View Controller". These icons represent IB objects. The objects are described by xml elements in the xib file, and that xml will direct the system to create the real objects in memory when the xib is loaded. While it's not technically correct to say the real objects are "created by IB", we can say that the specification for the real objects is built in IB. In other words, the xib file which results from an IB editing session contains a tree of specifications which will be used to create real objects at runtime.
    Btw, to graphically see the tree of xib objects (the "view hierarchy", find the +View Mode+ switch in the upper-left corner of the xib window. Select the Center position of that switch so the window displays a two column table with a tree of small icons to the left. This is the xib view I recommend for all your work.
    Also where is the instance of the main application created?(not A.app if you know what I mean)
    The Application object is created by the [UIApplicationMain()|http://developer.apple.com/iPhone/library/documentation/UI Kit/Reference/UIKitFunctionReference/Reference/reference.html#//apple_ref/doc/ui d/TP40006894-CH3-SW7] function called by main() in main.m. The MainWindow.xib is then loaded, and the Application object is given ownership of that xib. This means that the File's Owner proxy object represents the real Application object, so all connections to File's Owner become connections to the real Application object.
    Note that the File's Owner cube is transparent. This is IB's way of denoting a proxy object. The First Responder is actually a proxy of a different kind, but let's not go there now.
    \- Ray

  • A question about calling classes

    Hi,
    I have a question regarding software design so that each class is independent of other.
    public class A
        public void methodA()
                 B m_B=new B();
              String strA=m_B.getBString();
              System.out.println(strA);
    public class B
       public String getBString()
                      return "someString";
    }My question: Is it possible to call the method in class B from class A without creating an instance of class B in method of class A ?
    I am trying to figure out if this can be done using interfaces and abstract classes.
    I am waiting for some suggestions and if you have completely different suggestion then I am open for it too.
    thanks in advance,
    @debug.

    interface I {
        String getString();
    class B implements I {
        public String getString() { return "someString";}
    class A {
        private I foo;
        public void setFoo(I foo) {this.foo = foo;}
        public I getFoo() {return foo;}
        public void methodA() {
          System.out.println(getFoo().getString());
    public class Main {
        public static void main(String[] args) {
            A a = new A();
            a.setFoo(new B());
            a.methodA();
    }There's one problem with decoupling A and B in this case - A's method creates an instance of B. The above is one solution. There are many others.

Maybe you are looking for

  • Abap proxy and java proxy

    Hi Could you plz tell me when should we select ABAP Proxy and when should java proxy ?? Is it like that in SAP systems we use ABAP proxy and non-sap systems we use JAVA proxy ?? Thanks Kumar

  • Combination Prompts from Bex and BO Fileters in Dashboard 4.1

    Hi experts, I have Bex Query contains 3 prompts and i have created Dashboard on top of that Bex Query now i want to add 2 more prompts in the same dashboard but from BO Side not From Bex Side(i have some constraints from business to add prompts in Be

  • Creating dynamic  list of values

    HI, While I am trying to create dynamic list of values over a table(table1) having the columns h_id ,head_foot and header.I gave the query for creating the dynamic list of values as select header d, header r from g.fw_header_footer order by 1 where d

  • Failure to start up and no chance to repair  nor verify disk

    Hi there, My problem is that I cannot restart my laptop MacBook Pro 17" 2.16 with OSX 10.5.1 All I get is a the loading screen and when I insert leopard disc & hold down c key to repair the disk or verify, it won't let me giving me errors: Invalid no

  • Adapter Level Error To be Delivered

    Hi Guys,   i got few messages status with status as " To be Delivered" in Receiver Adapter level. i tried to resend the message from Runtime work bench, its not working. generally i got this type of status at target adapter level. everytime i did res