Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Swing method call makes WOBootstrap appear



There is a flag (can't remember - I think I posted to the list before) that tells the system not to make a WindowServer connection if at all possible.

Karl

On Nov 17, 2003, at 3:11 PM, Brendan Duddridge wrote:

Hi,

I9m calling a couple of Java swing methods from my within my WO app in order
to extract the links from an HTML document.


Here9s the code:

int index = 1;
String displayText = null;
StringReader rd = new StringReader(item.itemValue());
// Parse the HTML
EditorKit kit = new HTMLEditorKit();
HTMLDocument doc = (HTMLDocument)kit.createDefaultDocument();
kit.read(rd, doc, 0);

// Find all the A elements in the HTML document
HTMLDocument.Iterator it = doc.getIterator(HTML.Tag.A);
while (it.isValid()) {
    SimpleAttributeSet s = (SimpleAttributeSet)it.getAttributes();

    String link = (String)s.getAttribute(HTML.Attribute.HREF);
    NSLog.out.appendln("*** found link: " + link);
    if (link != null) {
        // Add the link to the result list
        linkArray.addObject(link);
    }
    it.next();
}

When I get to the point in my application where I execute this code, the
WOBoostrap icon pops up on my Dock. The code works correctly as expected.
I'm just not sure what's going to happen in a deployment environment where
there are no users logged in on my Xserves and in fact, since my deployment
Xserve is a Cluster node, there is no video card available anyway.


Will this cause a problem? My deployment environment is Panther Server
10.3.1, WO 5.2.2, Java 1.4.1.

I suspect since Java 1.4.1 has support for headless operation I would think
that it's ok.


Does anyone know why the WOBoostrap application shows itself when calling
this code? Will it be a problem in deployment?



Thanks,

___________________________

Brendan Duddridge

ClickSpace Interactive Inc.
Calgary & Vancouver, Canada
(403) 277-5591
http://www.clickspace.com
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.



--

The only problem with life is that the background music sucks.

Homepage:
     http://homepage.mac.com/khsu/index.html
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Swing method call makes WOBootstrap appear (From: Brendan Duddridge <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.