 |
 |
Index ‹ java-programmer
|
- Previous
- 1
- getParameterMetaData() throwing UnsupportedOperationException?Hi all,
Pls tell me why getParameterMetaData() of PreparedStatement is
throwing java.lang.UnsupportedOperationException
(pls see below code)
i guess the jdbc driver does not implement the method? is it correct?
Is it a problem with MS Access database?
Is there any solution to this?
Any comments are highly appreciated,
Regards,
Dhanan
code snippet: ..............
..............
String DEFAULT_DRIVER = "sun.jdbc.odbc.JdbcOdbcDriver";
String DEFAULT_URL = "jdbc:odbc:DRIVER={Microsoft Access
Driver (*.mdb)};DBQ=c:\\db1.mdb";
Class.forName(DEFAULT_DRIVER);
Connection con =
DriverManager.getConnection(DEFAULT_URL,"test","testpwd");
PreparedStatement ps = con.prepareStatement("Select * from Table1
where f1 = ? and f2 = ?");
ps.setString(1, "test");
ps.setString(2, "test");
ResultSet rs = ps.executeQuery();
while(rs.next())
{
System.out.println(b);
}
System.out.println("Before getParameterMetaData()");
ParameterMetaData pmtdata = ps.getParameterMetaData();
System.out.println("Before getParameterCount");
System.out.println("Param count: " + pmtdata.getParameterCount());
rs.close();
cst.close();
con.close();
.............
.............
Stack trace:
java.lang.UnsupportedOperationException
at sun.jdbc.odbc.JdbcOdbcPreparedStatement.getParameterMetaData(JdbcOdbcPreparedStatement.java:3446)
- 2
- java applet html editorMicrosoft has provided lots of tools to develop web base html editors
for their developers... it's called MSHTML.
this language, has text selection, replace, hyperlinks, etc...
the problem with it, it's it does not work on any other platform. Just
windows with ie. That is ok, because in that case you cover at least
85% of the market. But still, it's not good enough...
is there anywhere i can find code example on developping a java applet
that edits HTML online? feed it with html content, modify the content
with BOLD, ITALIC etc... buttons, and get resultig html.
I've looked around, i've found some examples:
http://www.hotscripts.com/Java/Applets/Content_Management/
but all these examples cost a lot of $$$. it's bizarre...
I wonder if there any software i can use to decompile these examples
above and look at the code??? somebody, somewhere either has the code,
or is willing to sell an applet at a reasonable price...
Please let me know.
Tascien
- 5
- Looking for HTML Rendererhi,
i'm looking for a HTML rendered for java. some functionalities i want
are (1) be able to access the DOM tree for the HTML file and (2) given
some DOM object, find out its physical location (and maybe other
properties like color, size, etc) on the rendered page.
i know this is possible through IE but unfortunately, i can't use IE.
JRex (http://jrex.mozdev.org/) *seems* like it has what i want but i've
read that it doesn't satisfy (2). does anyone know how to achieve this?
thank you.
--
Xiaolei Li | email***@***.com | www.xiaolei.org
- 6
- 8
- Ant Exec task- getting back execution value into resultpropertyHi,
I am using CruiseControl over Ant and I am running an Exec task that
runs a perl script that returns at exit "0" or "1" to determine
execution status.
My problem is that the resultproperty that suppose to get the returned
code does not change after execution.
The Exec task looks like that:
<property name="BuildStatus" value="123"/>
<echo message="Build status before=${BuildStatus}" />
<exec executable="perl"
failonerror="false"
failifexecutionfails="false"
resultproperty="${BuildStatus}"
output="output.txt"
dir="/scripts/">
<arg line="BuildAll.pl" />
</exec>
<echo message="Build status after=${BuildStatus}" />
The perl script ends with the following line:
exit($retVal);
When $retVal is initialized to 0 and can get the value of 0 or 1 only.
On the 2 prints surrounding the exec task I get the same value of
${BuildStatus} which is the one it was initialized with (123).
I tried initializing the property in the start of the Ant build file.
same results.
I tried using the attributes: outputproperty and errorproperty in order
to catch the return code. It didn't helped.
my purpose with this, is to fail the build at the end of it based on
the value returned from the perl script.
Ant-1.6.5
CruiseControl- 2.5.0
Java-1.5.0_06
Platform- MacBook, 1.83 Duo, 1GB Ram
Thanks,
Itai Barami.
- 10
- Servlet Compiler Error.I need some help/assistance from one of you able people for always getting a
compiler error indicating that the line[s] "private StringBuffer
getConfigTable(ServletConfig config) {" AND the line "private StringBuffer
getContextTable(ServletContext context) {" are illegal starts of the
expression! I have tried to do some "workarounds" for this problem but I am
still getting that compiler error. Can anyone please help me with this?
(There MIGHT be one too many ending "}" 's at the bottom of the file, but
other than that what is the problem?
/* Well here I go again with tryin' my hand at creating a new servlet.
Incidentally, this particular servlet will be called the
*"ContainerServlet.java".
*/
package org.steve.burroughs;
import javax.servlet.*;
import javax.servlet.http.*;
import java.io.*;
import java.util.*;
public class ContainerServlet extends GenericServlet {
public void service( ServletRequest request, ServletResponse response)
throws
ServletException, IOException {
StringBuffer configTable = getConfigTable(getServletConfig() ) ;
StringBuffer contextTable = getContextTable(getServletContext() ) ;
response.setContentType( "text/html" );
PrintWriter steve = response.getWriter();
steve.println("<html><head><title>Why Can\'t I Get "+
"Screwed??</title><head><body>");
steve.println("<h1>Servlet Configuration Information</h1>" +
configTable + "<hr>");
steve.println("<h1>Servlet Context Information</h1>" +
contextTable);
steve.println("</body></html>");
steve.flush();
steve.close();
private StringBuffer getConfigTable(ServletConfig config) {
HTMLTable table = new HTMLTable ();
table.appendRow("Servlet Name", config.getServletName( ));
Enumeration e = config.getInitParameterNames() ;
while ( e.hasMoreElements() ) {
String pn = (String)e.nextElement();
String pv = config.getInitParameter(pn);
table.appendRow("Parameter : <code> " + pn +
"</code>", pv);
}
return table.toStringBuffer();
}
private StringBuffer getContextTable(ServletContext context) {
HTMLTable table = new HTMLTable ();
table.appendTitleRow("Attributes") ;
Enumeration e = context.getAttributeNames() ;
while ( e.hasMoreElements() ) {
String pn = (String)e.nextElement ();
Object po = context.getAttribute( pn);
String pv = " " ;
if( po instanceof String) {
pv = (String) context.getAttribute( pn);
} else if ( po instanceof String[]) {
String[] pa = (String[])context.getAttribute( pn);
for(int i = 0; i < pa.length; i++){
pv = pv + pa[i] + "<br>";
}
}
else {
pv = context.getAttribute( pn).toString();
}
table.appendRow("Attribute : <code> " + pn +
"</code>", pv);
}
}
}
}
- 10
- Java to XMLIs there a parser which converts Java Source Code to XML?
--
Sebastian Danicic web: http://www.doc.gold.ac.uk/~mas01sd
Department of Computing, e-mail: email***@***.com
Goldsmiths College, Dept web: http://www.doc.gold.ac.uk
University of London, tel +44(0)207 9197868
London SE14 6NW. fax +44(0)870 0514569
- 10
- Thread garbage collectionWhat happens if a Thread is available for garbage collection yet still
running?
I guess the answer is obvious. The thread executes to completion or is
terminated with the garbage collection process at some later unguaranteed
time. Correct?
I'm asking because I'm reusing the same reference to a thread to create a
new one on an event. I just realized that I'm probably leaving a ton of
orphaned threads (which will soon be fixed).
Thanks!
- 13
- thread errori face the following error..
i have a JTextPanel and a thread that checks every 1sec if there is data
in an imputstream and write them to the text panel.. i have also a
button with which i want to "pause" the thread...
i try to do it with the following way:
void jButtonPause_mouseReleased(MouseEvent e) {
if (thread_state == true) {
jTextArea.append("\n try to stop thread \n");
try {
synchronized (this) {
t.notify();
t.wait();
}
thread_state = false;
jButtonPause.setText("Resume");
}
catch (InterruptedException ex) {
jTextArea.append(ex.getMessage());
}
}
else {
synchronized (this) {
t.notify();
}
thread_state = true;
jButtonPause.setText("Pause");
}
}
the above is the code for the button. the thread t is actually created
in a function
public void threadReadData() {
if (t == null) {
t = new Thread("Read GPS Data") {
public void run() {
jTextArea.setText("");
.
.
.
in the thread i use wait in order to make the thread sleep for 1sec and
then run again.
And now the problem.. when i press the button i get a
java.lang.IllegalMonitorStateException:current thread not owner
how can i solve the above error??
Best regards
Mandilas Antonis
- 13
- Threads java.lang.NullPointerExceptionHi there I was wondering if anyone can help me please.
I ve been working on a simple chat server program and it works when the
server handles one client at the time. I ve been trying to make the
server able to answer clients requests at the same time with threads.
I always get the same error message when I run the server:
java.lang.NullPointerException
at chatserverq3.ServerGUI.processClientRequests(ServerGUI.java:113)
at chatserverq3.ServerGUI.run(ServerGUI.java:73)
at java.lang.Thread.run(Thread.java:484)
This is the client code:
import java.awt.*;
import javax.swing.*;
import java.awt.event.*;
import java.io.*;
import java.net.*;
public class ClientGUI extends JFrame implements ActionListener
{
private JTextField nameField;
private JLabel nameLabel;
private JLabel areaLabel;
private JPanel topPanel, botPanel;
private JButton connectButton;
private JTextArea listArea;
private InputStream is;
private OutputStream os;
private BufferedReader fromServer;
private Socket socket;
private PrintWriter toServer;
static final String SERVER_ADDRESS = "127.0.0.1";
static final int SERVER_PORT_NUMBER = 4000;
static final String CLIENT_LOGGINGOFF = "Exit";
//constructor for the client GUI
public ClientGUI(String title)
{
setSize(400, 400);
setTitle(title);
setLocation(100, 100);
nameLabel = new JLabel("Name");
nameField = new JTextField(10);
areaLabel = new JLabel("Connected Users");
topPanel = new JPanel();
topPanel.setLayout(new BorderLayout());
botPanel = new JPanel();
connectButton = new JButton("Connect");
connectButton.addActionListener(this);
listArea = new JTextArea(10, 30);
JScrollPane scr = new JScrollPane(listArea);
topPanel.add(nameField, "West");
topPanel.add(nameLabel, "Center");
topPanel.add(connectButton, "East");
botPanel.add(areaLabel);
botPanel.add(listArea);
getContentPane().add(topPanel, "North");
getContentPane().add(botPanel, "Center");
setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
}
//attempts to connect the client to the server
private void connectServer()
{
try
{
socket = new Socket(SERVER_ADDRESS, SERVER_PORT_NUMBER);
openStreams();
}
catch(IOException e)
{
System.out.println("Trouble contacting the server " + e);
}
}
private void open()throws IOException
{
final boolean AUTO_FLUSH = true;
is = socket.getInputStream();
fromServer = new BufferedReader(new InputStreamReader(is));
os = socket.getOutputStream();
toServer = new PrintWriter(os, AUTO_FLUSH);
}
//action performed when the client GUI button is pressed
public void actionPerformed(ActionEvent a)
{
String buttonLabel = connectButton.getText();
String userName = nameField.getText();
try
{
if((buttonLabel == "Connect")&&(userName.length()> 0))
{
connectToServer();
sendUserName(userName);
connectButton.setText("Disconnect");
}
else
{
logOff(userName);
connectButton.setText("Connect");
}
}
catch(IOException e)
{
System.out.println("Problem with the server " + e);
}
}
private void close()throws IOException
{
toServer.close();
os.close();
fromServer.close();
is.close();
}
//sends the user name to the server
private void sendUserName(String aName)throws IOException
{
String reply;
String uName = aName;
toServer.println(uName + " logged on");
reply = fromServer.readLine();
listArea.setText(reply);
}
//notifies the server a client has logged off
private void logOff(String aName)throws IOException
{
String uName = aName;
toServer.println(uName + " logged off");
listArea.setText("");
toServer.println(CLIENT_LOGGINGOFF);
closeStreams();
socket.close();
}
}
public class Main {
public static void main(String[] args)
{
ClientGUI cg = new ClientGUI("ChatClient");
cg.setVisible(true);
}
}
The server code is:
import java.awt.*;
import javax.swing.*;
import java.awt.event.*;
import java.io.*;
import java.net.*;
import java.util.*;
public class ServerGUI extends JFrame implements Runnable
{
private JTextArea logArea;
private JLabel logLabel;
private JPanel logPanel;
private ServerSocket ss;
private Socket socket;
private InputStream is;
private OutputStream os;
private PrintWriter toClient;
private BufferedReader fromClient;
static final int PORT_NUMBER = 4000;
static final String CLIENT_LOGGINGOFF = "Exit";
//constructor for the Server GUI
public ServerGUI(String title)
{
setSize(400, 400);
setTitle(title);
setLocation(100, 100);
logArea = new JTextArea(15, 30);
JScrollPane scr = new JScrollPane(logArea);
logLabel = new JLabel("Logging history");
logPanel = new JPanel();
logPanel.add(logLabel);
logPanel.add(logArea);
getContentPane().add(logPanel);
setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
}
//constructor for the server to set the socket to handle a new thread
public ServerGUI(Socket s)
{
socket = s;
}
public void run()
{
try
{
while(true)
{
openStreams();
processClientRequests();
closeStreams();
socket.close();
}
}
catch(IOException e)
{
System.out.println("Trouble with a connection " + e);
}
}
//helper method for the class to set up the streams
private void open() throws IOException
{
final boolean AUTO_FLUSH = true;
is = socket.getInputStream();
fromClient = new BufferedReader(new InputStreamReader(is));
os = socket.getOutputStream();
toClient = new PrintWriter(os, AUTO_FLUSH);
}
//process the string from received from each client
private void processRequests() throws IOException
{
String userName;
String reply;
int numberOfFields = 3;
String [] fieldContents = new String[numberOfFields];
userName = fromClient.readLine();
while(!(userName.equals(CLIENT_LOGGINGOFF)))
{
StringTokenizer tokensIn = new StringTokenizer(userName, " ");
int i = 0;
while(tokensIn.hasMoreTokens())
{
fieldContents[i] = tokensIn.nextToken();
i++;
}
reply = fieldContents[0];
toClient.println(reply);
logArea.append("[ " + reply + " ] "+ fieldContents[1]+"
"+fieldContents[2]+"\n");
userName = fromClient.readLine();
}
}
//helper method to close the streams with each client
private void close() throws IOException
{
toClient.close();
os.close();
fromClient.close();
is.close();
}
}
import java.net.*;
import java.io.*;
public class ChatHandler
{
static final int PORT_NUMBER = 4000;
public ChatHandler()
{
}
public void run()
{
try
{
ServerSocket server = new ServerSocket(PORT_NUMBER);
while(true)
{
Socket client = server.accept ();
System.out.println ("Accepted from " + client.getInetAddress ());
Thread aThread = new Thread(new ServerGUI(client));
aThread.start ();
}
}
catch(IOException e)
{
System.out.println("Trouble with ServerSocket, port
"+PORT_NUMBER +": " + e);
}
}
}
public class Main {
public static void main(String[] args)
{
ServerGUI sg = new ServerGUI("ChatServer");
sg.setVisible(true);
ChatHandler cH = new ChatHandler();
cH.run();
}
}
It is the first time I use threads and maybe there is something I dont
understand. Can anyone point me to the right direction please? I think
the problem may be with the 2 server constructor but I am not sure how
to solve it.
Cheers Pat
- 14
- 15
- Problem with Struts' SwitchActionHi all!
I have problem with SwitchAction. Simplified workflow is following:
- main module (struts-config.xml):
/start.do (SwitchAction, passed params: prefix=/module1; page=/search.jsp)
This action is used to properly enter Struts framework.
- /module1 module (struts-config-module1.xml):
Form in search.jsp submits to the following action:
/module1/search.do (SwitchAction, passed params: prefix=/search;
page=/search.do)
This action switches to the search module.
- /search module (struts-config-search.xml):
/search/search.do (SearchAction)
SearchAction is custom action and it forwards to the another SwitchAction in
the /search module (/search/performSearch.do). SwitchAction params are added
within SearchAction to the path.
/search/performSearch.do (SwitchAction passed params: prefix=/module1;
page=/performSearch.do)
Now here occurs the problem. When SwitchAction of the
/search/performSearch.do action seeks for prefix param from the request
object, it gets old value "/search". Somehow value "/module1" is lost,
although I have set it in the SearchAction. This results with infinite loop,
because Struts does not switch from /search module to /module1 module and
/performSearch exists in both modules.
So, somehow when I chain my SearchAction and SwitchAction, new value of the
prefix param which is passed to the SwitchAction is lost.
Platform is WSAD 5.1.
Thanks,
BB
- 15
- flicker when dragging over a jtree nodeWhen I drag onto a row (not neccessary over the node icon), the
tree node icon looked flicker. Is there any way to prevent this?
Is there anything to do with dragOver?
thanks
- 15
- Writing to a file... I have a program that has the following method to save data to a text
file:
private static File mUserFile = null;
private static String mUserSolutions = "C:/solutions/User_solutions.txt";
public void saveSolution(String pGameBoard, String pSolution, char pLevel) {
if (mUserFile == null)
mUserFile = new File(mUserSolutions);
try {
PrintWriter printWriter = null;
if (!mUserFile.exists()) {
printWriter = new PrintWriter(new
FileOutputStream(mUserFile));
} else {
printWriter = new PrintWriter(new FileOutputStream(mUserFile,
true));
}
Solution solution = new Solution(pGameBoard, pSolution, pLevel);
saveSolution(solution);
printWriter.println(pLevel + ":" + pGameBoard + ":" + pSolution);
printWriter.flush();
printWriter.close();
} catch (FileNotFoundException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
saveSolution(solution) just saves the object to an internal table.
When I execute this code in Eclipse, it will create or append to my file
like I expect but when I create an executable jar file and run it, the
screen says that it performed the save but there isn't any file created and
if I create the file manually, it doesn't append to it. Any help would be
greatly appreciated.
- 15
- Need Abinito and Tibco (5) - Req.Hi,
These are the requirements currently open.
Req. ID: Req-030520081038 - Ab initio Developer
Primary Skills: Abinitio, ETL, ORACLE,GDE (Ab-initio), SQL * Net, Net
8, SQL * Loader, SQL * Plus, Oracle DBA Studio, ODBC
Secondary Skills: Unix & Windows NT
Description: Must have strong ETL development background and object
oriented analysis and design experience. Atleast 1 to 2 years of
Abinitio experience is required. Strong experience in Perl, Shell
scripting, SQL, PL/SQL and other programming languages and be able to
optimize and tune complex queries. Oracle 9i design, data model
maintenance and data loading experience is required. Strong
interpersonal and communication skills (both written and verbal) are
required. Ability to work nights and weekends when necessary due to
project deadlines and support issues is required.
Knowledge of AS400, Web Methods, BI tools like Business Objects and
Project
Rate: Open, Job Type: Contract, Total Exp: 6 Years, Duration: 1
Year, Number Of Openings: 1, Location: Chicago-IL
Req. ID: Req-030520081040 - Tibco Developers (5)
Description:
3 years experience in a complex business and information systems
environment
2+ years Tibco BusinessWorks Experience
2+ years of Web Services experience (XML/SOAP/WSDL)
Eclipse-based IDE experience for coding, testing, debugging of Java
applications.
1+ years of JDBC programming experience with oracle preferred
Experience developing technical design specifications in a structure
development methodology
Outstanding oral, written, and presentation skills
Ability to work collaboratively with diverse groups
Ability to travel up to 10% of the time
Comfortable in both a UNIX and windows based environment
Rate: Open, Job Type: Contract, Duration: 6 Months, Number Of
Openings: 5, Location: St. Louis, MO
I will contact you, if I need more information.
Regards
Craig
|
| Author |
Message |
Arne Vajh鴍

|
Posted: 2007-10-16 7:56:00 |
Top |
java-programmer, Great SWT Program
email***@***.com wrote:
> On Oct 15, 7:04 pm, email***@***.com (Bent C Dalager) wrote:
>> In article <email***@***.com>,
>> I have explained this earlier. I do not care to do so again.
>
> I don't care for your tone, mister.
>> I will argue with whomever I please.
>
> Then you will face the consequences.
Why is it that I am thinking of the saying: "Empty barrels
make most noise" ?
:-)
Arne
|
| |
|
| |
 |
Arne Vajh鴍

|
Posted: 2007-10-16 7:56:00 |
Top |
java-programmer >> Great SWT Program
email***@***.com wrote:
> On Oct 15, 7:04 pm, email***@***.com (Bent C Dalager) wrote:
>> In article <email***@***.com>,
>> I have explained this earlier. I do not care to do so again.
>
> I don't care for your tone, mister.
>> I will argue with whomever I please.
>
> Then you will face the consequences.
Why is it that I am thinking of the saying: "Empty barrels
make most noise" ?
:-)
Arne
|
| |
|
| |
 |
Owen Jacobson

|
Posted: 2007-10-16 8:15:00 |
Top |
java-programmer >> Great SWT Program
On Oct 15, 4:49 pm, Lew <email***@***.com> wrote:
> <email***@***.com> wrote:
> >> It's the time spent traveling and waiting in line, rather than the
> >> time spent actually performing your transaction once you get to the
> >> head of the queue, that would be prohibitive.
> Bent C Dalager wrote:
> > I don't know where you live, but someone needs to go kick your banks
> > in the ass and tell them the rest of the world has moved on to the
> > 21st century and if they don't intend to be left entirely behind they
> > might want to wake up and smell the coffee.
>
> > There are banks now that specialize in never ever having to meet their
> > customers face to face - not even to establish accounts or take up
> > mortgages. They have neither branches nor tellers - they only have an
> > HQ and a suitably powerful server farm to handle all the online
> > requests.
>
> > One of these is skandiabanken.no (in Norway)
>
> I'm willing to bet that the banks where he lives are just as forward-thinking.
>
Actually, with a few exceptions, banks in Canada are remarkably
resistant to setting up temporary disposable accounts for various
purposes. While very forward-thinking in terms of physical at-the-
merchant transactions (the Interac network has astonishing coverage
and stability), online merchant transactions don't seem to be
gathering the same level of support. My own bank, BMO... *checks*
allows you to open new savings and chequing accounts from the web once
you have at least one account (putting the lie to herr pseudonym's
claim about always needing to go to the bank for that, too), but
doesn't seem to offer any form of disposable account that I can find.
That said, there are banks operating in Canada that until very
recently had no branches as well, including ING Direct and President's
Choice. Some options are definitely available.
> --
> Lew
By the way, either your sig separator is broken ("\n-- \n", saith the
RFC), or GG is misbehaving again. Even odds.
Cheers,
Owen
|
| |
|
| |
 |
Owen Jacobson

|
Posted: 2007-10-16 8:31:00 |
Top |
java-programmer >> Great SWT Program
On Oct 15, 4:21 pm, email***@***.com wrote:
> On Oct 15, 7:04 pm, email***@***.com (Bent C Dalager) wrote:
>
> > In article <email***@***.com>,
>
> > <email***@***.com> wrote:
> > >Ergo, getting a new account for every online purchase means waiting in
> > >line at the bank for every online purchase.
...
> > >This is irrefutable logic. You can claim that the system is
> > >"different" until you're blue in the face, but this won't alter the
> > >facts and the conclusions that follow inevitably from them by
> > >deductive reasoning.
You might consider that people say things are different from your
expectations because they've tried it and discovered that things are
different from your expectations, not because they're lying to you.
Furthermore, implying that they're lying is an attack, remember? And
you never attack people.
So stop implying other posters are lying, whether you mean to or
not[0].
> > When the map doesn't fit the landscape, one corrects the map.
>
> Exactly.
>
> Your saying stuff = the map.
> My actual experience in such matters = the landscape.
> Your map doesn't fit the landscape.
> Change your map.
The fact that your bank and, apparently, every bank you've done
business with (and that can't be very many, unless you go through them
as fast as you go through identities) requires you to show up in
person to open an account does not preclude the existence of banks
that have no such requirement. My own bank (BMO) allows people who
already have an account to open more (non-disposable, admittedly)
accounts from their online banking application without ever visiting a
branch, for example; if that's possible, then surely the creation of
temporary, limited-balance accounts can't be any harder or less
plausible. It's all bits anyways.
[0] For what it's worth, I actually don't believe you meant to imply
anyone was lying. Nonetheless, you did so.
|
| |
|
| |
 |
Owen Jacobson

|
Posted: 2007-10-16 8:37:00 |
Top |
java-programmer >> Great SWT Program
On Oct 15, 4:21 pm, email***@***.com wrote:
> On Oct 15, 7:04 pm, email***@***.com (Bent C Dalager) wrote:
>
> > In article <email***@***.com>,
>
> > <email***@***.com> wrote:
> > >Ergo, getting a new account for every online purchase means waiting in
> > >line at the bank for every online purchase.
...
> > >This is irrefutable logic. You can claim that the system is
> > >"different" until you're blue in the face, but this won't alter the
> > >facts and the conclusions that follow inevitably from them by
> > >deductive reasoning.
You might consider that people say things are different from your
expectations because they've tried it and discovered that things are
different from your expectations, not because they're lying to you.
Furthermore, implying that they're lying is an attack, remember? And
you never attack people.
So stop implying other posters are lying, whether you mean to or
not[0].
> > When the map doesn't fit the landscape, one corrects the map.
>
> Exactly.
>
> Your saying stuff = the map.
> My actual experience in such matters = the landscape.
> Your map doesn't fit the landscape.
> Change your map.
The fact that your bank and, apparently, every bank you've done
business with (and that can't be very many, unless you go through them
as fast as you go through identities) requires you to show up in
person to open an account does not preclude the existence of banks
that have no such requirement. My own bank (BMO) allows people who
already have an account to open more (non-disposable, admittedly)
accounts from their online banking application without ever visiting a
branch, for example; if that's possible, then surely the creation of
temporary, limited-balance accounts can't be any harder or less
plausible. It's all bits anyways.
[0] For what it's worth, I actually don't believe you meant to imply
anyone was lying. Nonetheless, you did so.
|
| |
|
| |
 |
Owen Jacobson

|
Posted: 2007-10-16 8:54:00 |
Top |
java-programmer >> Great SWT Program
On Oct 15, 4:14 pm, email***@***.com wrote:
> On Oct 15, 4:35 pm, Roger Lindsj?<email***@***.com> wrote:
>
> > *) Actually VIM 7.1.12
>
> In other words, not actually what I was saying. :P
I suspect if you took a poll of all the people who call themselves vi
users, you'd discover that the vast majority of them use some recent
release of VIM, making VIM, de facto, "vi". You may have used an old
version of VIM; you may have used a distro which configured it badly
(there are no shortage of thse); you may have used a different
implementation of the vi editor entirely. That's irrelevant. In this
day and age, if you talk about "vi", most people will interpolate
"vim" until told otherwise.
I know that if you took a similar poll of emacs users, you'd discover
that most of them use either GNU Emacs or XEmacs (making those the de
facto definition of "emacs" today), both of which are quite capable of
all the feats you expect from a GUI editor: high-quality unicode
support, CUA compliance on platforms that have such, mouse-driven
features, scrollbars, inline images, et multiple cetera. They are
also highly consistent with each other, making skills learned on GNU
Emacs rather portable to XEmacs and vice-versa; I'd be willing to bet
that if you can get GOSMACS to run on anything modern the same would
be true of it.
The fact that you either used a version missing those features or were
unable to locate those features in no way invalidates their existence;
most modern desktop[0] linux distros provide defaults such that those
features are immediately available when you start emacs from a desktop
session[1], and emacs packages for non-linux platforms are configured
as the packager chooses.
There is, for example, a packaging of GNU Emacs for OS X[2] which,
while retaining the emacs shortcuts, *also* supports the Apple HIG
shortcuts -- possible, since the HIG shortcuts all use the Cmd key and
the emacs shortcuts all use the Ctrl key. Similarly, it uses the
Quartz rendering framework as much as possible, giving it rather good
support for varying fonts and international characters.
These definitions do not change overnight; I only foresee VIM ceasing
to be the default interpretation of "vi", or GNU Emacs and XEmacs
ceasing to share the default interpretation of "emacs" if another
variant of either editor comes along that is a marked improvent, for
the current userbase, over the current high-quality offerings.
-o
[0] Non-desktop-targetted distros are usually also aimed at people who
have signifigant UNIX experience already, which usually includes
competence with either or both of emacs or vi.
[1] While still starting in character mode if no desktop is available,
no less. Some of the GUI features carry over to character mode,
including unicode support as good as the output in use. If the output
in use is, for example, a remote SSH login with no X forwarding via a
graphical SSH program such as gnome-terminal or putty, the unicode
support is extremely good. If the output in use is a raw BIOS
console, the unicode support is... less good, but functional.
[2] <http://emacs-app.sourceforge.net/> Note that for an alpha
release its list of bugs relating to rendering contains a single item,
which suggests that the underlying support for different rendering
mechanisms was rather high quality before the Emacs.app guys got
anywhere near it, or that the Emacs.app guys are geniuses.
|
| |
|
| |
 |
Mike Schilling

|
Posted: 2007-10-16 10:44:00 |
Top |
java-programmer >> Great SWT Program
email***@***.com wrote:
[snip the usual blather]
You're blathering. As usual.
|
| |
|
| |
 |
blmblm

|
Posted: 2007-10-16 16:47:00 |
Top |
java-programmer >> Great SWT Program
In article <email***@***.com>,
<email***@***.com> wrote:
> On Oct 14, 12:39 pm, email***@***.com <email***@***.com>
> wrote:
[ snip ]
> > People who don't mind dealing with a cryptic interface can
> > readily distinguish device files from regular files.
>
> Only by manually issuing some arcane command they'd have to know about
> first. It isn't visually apparent in a straight vanilla listing of
> files.
Actually, it might be, depending on what you mean by "straight
vanilla listing of files". Just typing "ls" in a vanilla account
on a Fedora 7 system to which I have access gives a list of files
and directories in which different colors are used for different
kinds of files. Device files appear in a different color from
other kinds of files. <shrug>
Of course, "people who don't mind dealing with a cryptic interface"
are probably going to be willing to .... Whatever.
[ snip ]
> > I guess if by "Unix internals" you mean not only the actual code
> > but also basic system concepts. For example, you probably have to
> > have some vague notion about Unix's three-level file permissions
> > scheme to understand what files are accessible to whom. I'm not
> > sure I'd call that "Unix internals". Maybe you would. <shrug>
>
> Basic things such as files and directories and permissions are part of
> the UI rather than part of the internals. I was talking about stuff
> like the cryptic error messages, anything that requires hand-hacking
> things like termcap or fstab, or even refers to these, and various
> other things of this sort. Things requiring knowledge of shell command
> syntax or even the full scripting language. Anything whose input needs
> certain characters to be escaped. Etc.
Knowledge of how to use the shell is "internals" .... Seems like
a strange definition of me, but -- whatever.
--
B. L. Massingill
ObDisclaimer: I don't speak for my employers; they return the favor.
|
| |
|
| |
 |
blmblm

|
Posted: 2007-10-16 16:55:00 |
Top |
java-programmer >> Great SWT Program
In article <email***@***.com>,
<email***@***.com> wrote:
> On Oct 14, 12:15 pm, email***@***.com <email***@***.com>
> wrote:
> > Initially -- "what the !@#$ is a project? a workspace?
> > a perspective? I just want to write some code and run it!"
>
> For that, Notepad is better, as is a non-Java language, since Java has
> you juggle multiple source files and at least one package to do
> anything non-trivial, as well as write a fair amount of boilerplate.
>
> Projects, workspaces, and perspectives are going to come up a lot when
> working with *any* IDE.
I guess. The only other IDE I have more than trivial exposure to
is Borland's Together. I seem to remember that it has a notion
of projects; I can't remember about workspaces and perspectives.
I still maintain that all of this is potentially confusing to
someone new to IDEs in general.
> Perspectives amount to having a few different
> tables with different tools on them, oriented around different
> purposes. You should not mind them if you can tolerate vi's modes,
> which don't even provide any visual cues to the user(!)...
vi doesn't. vim does.
[ snip ]
> > I've also heard a few (college-age) students new to the tool
> > complain that it's too big and complicated and they can't figure
> > it out. And these are people who *did* grow up with Windows.
>
> Bah. For just plain coding in Java without using any version control
> or anything, it's more or less install it, run it, create a project
> with the default settings, and create class source files in which you
> type in some code. When I started using it I was using it in a basic
> but effective way within literally minutes.
Had you used another IDE previously?
> Less than an hour later I
> had a "hello, world" run successfully. Of course I've learned various
> tricks and shortcuts for particular functionality since then, but
> those sped up what I could do pretty much from the beginning; it was
> usable from the outset, rather than only with extensive training.
>
> > I think in a lot of ways the tool just doesn't mesh all that well
> > with my mental model of how software should work. <shrug>
>
> Your mental model of software is obviously weird. Perhaps you should
> try to describe it.
I've been trying, in that other branch of this thread where at
one point the posts were almost a thousand lines long. It has
something to do with scriptabiity and interoperability with
text-mode tools. I'm not sure I can do any better than that,
in the time I'm willing to spend right now.
--
B. L. Massingill
ObDisclaimer: I don't speak for my employers; they return the favor.
|
| |
|
| |
 |
blmblm

|
Posted: 2007-10-16 17:01:00 |
Top |
java-programmer >> Great SWT Program
In article <email***@***.com>,
<email***@***.com> wrote:
> On Oct 14, 9:27 am, Patricia Shanahan <email***@***.com> wrote:
> > email***@***.com wrote:
[ snip ]
> > Teaching how to program should be part of a computer science course,
> > just as teaching about geography should be part of a geography course.
> > However, all university courses, regardless of nominal topic, are
> > supposed to teach how to think and learn, and those are the really
> > important skills.
>
> Note that I suggested teaching programming skills that will outlast
> any specific programming language. As for "thinking and learning", I
> don't see that exposure to awkward and obsolete UIs helps much with
> that. More likely, such an interface gets in the way of doing what
> you're really there to do.
Maybe. Then again, programming with an IDE rather obscures the
fact that source code is plain text, converted to object code and
then an executable with a compiler. But the department where
I teach seems to focus more than some do on having students
understand what's happening at a fairly low level. Whether in
the long run that's better or worse than focusing solely, or
almost solely, on something higher-level .... I don't know.
> Trying to program and (especially) debug
> will do a lot to teach thinking and problem-solving skills, and
> working with new APIs or languages a few times will help with the "how
> to learn" part. Reading the documentation and googling are two of the
> major skills here, but will tend to get instilled anyway.
>
> However, having a student attempt to do something through a narrow and
> clunky and oddball interface won't teach them anything but what
> frustration feels like, I expect. And it will drastically slow down
> everything else in the meantime.
--
B. L. Massingill
ObDisclaimer: I don't speak for my employers; they return the favor.
|
| |
|
| |
 |
blmblm

|
Posted: 2007-10-16 17:11:00 |
Top |
java-programmer >> Great SWT Program
In article <email***@***.com>,
<email***@***.com> wrote:
> On Oct 14, 1:39 pm, email***@***.com <email***@***.com> wrote:
> > Well, if you believe that GUIs are the be-all and end-all of user
> > interfaces, that might be true. I'm not convinced they are -- I'm
> > not sure what the user interface of 2057 will be like, but I have
> > no trouble believing it will be as foreign to what we have now as
> > GUIs initially seemed to me. If one believes that maybe GUIs are
> > not the last word, it seems to me obvious that exposure to more
> > than one type of interface is a good thing, in making it clear that
> > there *is* more than one way to do things.
>
> This presupposes that they're all "different, but equal".
I don't agree that teaching people that there are different user
interfaces, and showing them one other than the one they're used
to, implies that all are equal.
> Bleeding-
> heart liberal bullshit. Some are better than others. First came
> patching or toggling stuff in by hand. Then came punched cards; a
> distinct improvement. Then line-oriented interactive software on text
> terminals -- actual interactive software! Then screen-oriented
> terminal mode stuff. Then the GUI. Each an improvement over the last,
> offloading more of the user's mental work onto the computer and
> simplifying the mechanics of interaction so that the mechanics would
> get out of the way easily and let the user focus their mental effort
> on the actual job they were doing instead of the mechanics of
> manipulating the interface. Also, each one providing a richer and more
> informative feedback as the user worked.
Just out of curiosity, how many of these have you actually used?
[ snip ]
> Eh? The only thing I foresee superseding OO is something that contains
> an OO subset, likely something aspect-oriented. Actually, interacting
> networks of OO or AO software seems likely to be the pinnacle; the
> final big challenge after dealing with crosscutting concerns is
> scaling things up robustly, and decomposing monoliths into interacting
> modules that have separate address spaces and run concurrently is the
> big thing there. A highly threaded program in a JVM is already rather
> like that, as given a bug-free JVM it won't actually matter that they
> technically share one address space.
>
> Aside from OO, what is there now?
That's not really the point, though, is it? The point is that if
humans are still doing "programming" in 2057, or perhaps even in
2027, will they still be doing it according to the object-oriented
paradigm, or will something else have come along?
But maybe your predictive powers are as perfect as .... No, no,
never mind.
[ snip ]
> > I guess you don't read man pages, then. Most of them have a section
> > called "FILES" at the end.
>
> Not from cover to cover; and nothing essential to normal use should be
> in technical appendices instead of the main matter anyway.
We were discussing the location of the input/source files for the
man pages, and their format. This is essential to normal use? How?
[ snip ]
--
B. L. Massingill
ObDisclaimer: I don't speak for my employers; they return the favor.
|
| |
|
| |
 |
blmblm

|
Posted: 2007-10-16 18:12:00 |
Top |
java-programmer >> Great SWT Program
In article <email***@***.com>,
<email***@***.com> wrote:
> On Oct 14, 2:47 pm, email***@***.com <email***@***.com> wrote:
> > Wow. And you really are just now finding out where it comes from?
> > after what you've said is many years of Usenet reading/posting?
> > Amazing. Not unimaginable, I guess, but amazing!
>
> Not really. It's used a lot on usenet, and lots of people don't know
> beans about unix, so ...
And you weren't ever curious about where it came from? Huh.
> > Serious response: \^ (backslash being something of a universal
> > "escape character" -- a convention followed in some aspects of
> > Java as well, no?)
>
> String literals. Programmers have to deal with such things. End users
> having to is a sign of a UI design problem.
But if the "end user" *is* a programmer .... Whatever.
[ snip ]
> > > It's not only not obvious, but apparently in conflict with one of the
> > > launch external command commands that you mentioned earlier. You had
> > > mentioned a :rls something to run ls and view stuff. Wouldn't :reg try
> > > to launch an executable named "eg" then?
> >
> > I mentioned ":r!<command>" to launch an external command and insert
> > its output into the text being edited. Notice the "!" there.
> > (Reading from a file is accomplished with ":r filename". Notice the
> > " " there.)
>
> So :r reads from an external source, and whatever's after the r
> specifies the particular source. What sort of source is "eg" then?
> Space is a file, ! is a shell command's output ... and eg is? :P
Part of the command rather than its arguments. Commands are
separated from their arguments by a space or punctuation.
Maybe that's weird too, though it strikes me as sensible, and
even in line with the conventions of natural language.
[ snip ]
> > > Maybe so, but there was definitely no mention of pastes, and I'm all
> > > too familiar with software (usually unix-developed and ported to
> > > Windoze, rather than native) that defines "undo" weirdly to "undo the
> > > last performed of some random, but predefined, proper subset of the
> > > possible operations", so if you do A, B, and C, and then undo twice,
> > > it may undo C and A rather than C and B.
> >
> > Huh. I don't know that I've observed behavior like that with vim
> > or emacs.
>
> Perhaps not, but I have observed behavior like that elsewhere.
Huh. Care to mention examples?
> > How many times do you have to be told that a text-mode tool
> > running in an terminal emulator window can use all the screen
> > real estate available, with fonts as small as the sharpest-eyed
> > youngster could want?
>
> How many times do you have to be told that when someone has the
> hardware capability to display like that, they may as well use a
> proper GUI editor instead?
Because I believe the latter to be a matter of opinion, while
the former is a matter of fact. There may be many reasons to
prefer something with a "proper" GUI to a text-mode application,
but "text-mode applications can't display more than 24 lines and
80 columns" isn't one of them -- well, if we're talking about
text-mode applications as they exist in 2007.
[ snip ]
> > How do you know vim has no mouse support? All I said was that
> > I didn't know whether it does. Turns out it does .... Off by
> > default, true. No need to rant about how awful that is; I can
> > almost construct your arguments myself.
>
> It has mouse support? How the hell? It's a console app!
Magic, I guess. I just tried it in a text-only console (not
a terminal emulator under a desktop environment, but one of
the Linux "virtual consoles"), and it works there too.
> [snip stylistic criticism]
>
> WTF?
I find your long paragraphs difficult to follow. If you're
interested in communicating with your readers, that might be
useful information. Or not, since you might easily conclude that
this is one more way in which this blmblm person is just weird.
> > I guess you missed the parts in previous posts where I said that
> > for me the keystrokes needed to operate vim long since became
> > automatic; I no more think "I need hjkl to move the cursor"
> > when I'm editing text with fim than I think "I need to press the
> > leftmost pedal to stop the car" when I'm driving. I'm sure this
> > is true in your world as well; you don't consciously think "oh,
> > I need the arrow keys to move the cursor", do you?
>
> No, but it's easy to tell which one does what. I reach automatically
> for the arrows and push the one pointing in the direction I want to
> go. You reach automatically for hjkl and then puzzle for a bit trying
> to remember which does what.
No. There's no conscious thought involved, any more than there's
conscious thought involved in figuring out which of the car's
pedals to push. Well, unless I've recently had the misfortune
to have had to edit text with some other tool. It's a bit like
trying to switch back and forth between a car with an automatic
transmission and one with a clutch -- when I was more accustomed to
the latter, sometimes I got a big surprise pressing the leftmost
pedal in, um, a "normal" car. (Go ahead -- tell me that just
proves again how much better an automatic is, since it's what
"everyone" drives.)
> Time gets wasted. You can find the key
> group as fast as I can, but it seems doubtful once there you can pick
> out the correct individual key as fast. Especially as they're not even
> arranged in a cross on most (all?) keyboards.
I've been using something vi-like for almost twenty years, as
best I can remember. Is it really unimaginable that in all those
hours the knowledge of which key does what would become a matter
of -- what did you call it not too long ago? motor memory? --
rather than conscious thought?
Apparently to you it is. <shrug>
> Also, even when not looking at the keyboard I can pick my arrow
> quickly, because the up arrow is flanked by empty space on both sides.
> Finding the corner formed by the up, left, and down arrows is easy by
> touch, and then it's easy to nail the intended key from there. While
> hjkl are buried in the middle of an amorphous mass of QWERTY, at least
> on standard keyboards.
Right on/near the "home key" positions that touch typists can easily
find.
> Even so, I tend to accurately find the specific
> letter I want to type without looking when typing actual text, but if
> I am reaching for "the up key" rather than "the letter L" or whatever,
> I'm going to be glancing down, more than likely. The letter L key is
> clearly labeled as such. My up arrow key also is. Yours isn't. Oops!
But I'm not "reaching for the up key".
> And even if it somehow magically is just as fast once learned, it's no
> faster, and it is surely much, much harder to learn. That's not a good
> cost/benefit ratio.
Could be. I don't know how many people who started with vim
actually use the hjkl keys for navigation. vim supports using the
arrow keys as well, and my guess is that many people who start out
with it rather than "real" vi just use what they're more used to
(arrow keys).
[ snip ]
> > It might, if it tried to autocomplete without being asked. It
> > doesn't. What did you think that "if I press tab" meant? (It's
> > how one requests filename completion.)
>
> Seems to pose a problem with aligning text. For that you normally want
> the tab key to do something else.
Context matters. It's unsurprising to me that pressing tab in the
middle of something intended to be interpreted by something like a
shell would do something different from pressing tab while entering
text. I guess you find this startling and weird, and yet -- what
happens when you press tab in your browser of choice? in Firefox
it seems to move to the next link, which seems a little different
from what it would mean if you were entering text in -- whatever
you use to compose text.
> > The fact that Eclipse "helpfully" tried to autocomplete things
> > without being asked is one of the things that irritates me about
> > it. Yes, I've heard that this feature can be turned off.
>
> AFAIR it pops down a menu with options you can choose none of and just
> keep typing. The one area where it gets in my way is if I want to move
> down or up for some reason and that menu's there at the time.
Just that it pops up -- I find that distracting. Maybe you get used
to it.
[ snip ]
> > I wonder whether something else will replace the Windows-style GUI
> > in your lifetime, and if so how you will cope.
>
> Most likely, that GUI will evolve, rather than change wholesale. After
> all, the full-screen text interface is sort of buried in a GUI
> everywhere there's a text box or a Notepad or something. The line-mode
> text interfaces of even older days of yore is embedded in the full-
> screen one
A primitive version of the line-mode text interface. That's kind
of the point I've been making. A lot of the key bindings that
were useful with the old interfaces now have other meanings.
One can argue, though, that the user base for the old key bindings
was a lot smaller than the user base accustomed to what Windows has
made the de facto standard. So maybe you'll be in luck, and those
key bindings you're used to will be the standard for the rest of
your life -- or the whole idea of key bindings will go away, to be
replaced by something you find easy to adapt to.
> when you happen not to be moving up or down, or making
> multi-line selections, and even in the GUI this way and also in single-
> line input fields. Whatever follows will probably subsume rather than
> completely replace the GUI, likely by adding more use of sound
> (including voice recognition) as an I/O channel and adding more
> possible abstractions and visualizations of data objects and
> structures and functionality groupings.
[ snip ]
> > > The latter especially is interesting. There is a "how to learn on your
> > > own" that can actually be self-perpetuating? Despite the total lack of
> > > standardization between apps?
> >
> > I keep telling you that there is. I guess you don't believe me.
>
> I keep telling you that I've *seen with my own eyes* that there isn't.
> You enter something at the command prompt, are in an interactive app,
> and ... it has nothing in common with that other one you fiddled
> around with yesterday. And neither with the one from Tuesday. Etc.
Your mileage differs from mine. I'm perfectly willing to believe
that for one reason another *you* can't, or don't want to,
get past the "need a local expert" phase with the old-Unix UI.
There could be many explanations for that -- other things you'd
rather be doing, lack of a local expert, belief that the UI you
have is superior, some other reason. I might even agree that your
explanation makes sense *for you*, and perhaps for many or even
most people.
You seem to be saying, though, that because *you* can't or won't do
it, no one can, and dismissing my claims that I'm a counterexample.
Am I not understanding you?
[ snip ]
> > > No, those were examples of things that crashed in ways that brought
> > > down the OS, rather than things that didn't install right.
> >
> > My point stands: "GUIs not perfect, sometimes worse than simpler
> > tools."
>
> I don't think the fact that they had GUIs somehow made them more
> likely to crash, or to bring other things down with them.
I do. To me programs with GUIs seem inherently more complex
than the old text-mode stuff, hence more likely to have bugs.
If nothing else, aren't they more likely to be multi-threaded?
which seems to me to be a known source of potential trouble ....
(Not that it would be in a perfect world, in which all developers
understood how to write multi-threaded code. But.)
[ snip ]
--
B. L. Massingill
ObDisclaimer: I don't speak for my employers; they return the favor.
|
| |
|
| |
 |
blmblm

|
Posted: 2007-10-16 18:37:00 |
Top |
java-programmer >> Great SWT Program
In article <email***@***.com>,
<email***@***.com> wrote:
> On Oct 14, 2:47 pm, email***@***.com <email***@***.com> wrote:
Okay, replied to most of what I wanted to already, but one more
thing ....
[ snip ]
> > > 1) why does anyone add capabilities that depend on modern hardware,
> > > when modern hardware makes the whole text-terminal mode of UI design
> > > obsolete anyway? Still not explained to my satisfaction.
> >
> > Maybe it has to do with some notion of frugality, or not discarding
> > something that still works very well within its limitations and
> > doesn't require the latest and most expensive hardware.
>
> Come off it. That 386 that's gathering dust in somebody's closet until
> they sell it to you on eBay for a whopping $50 is quite capable of
> presenting a reasonable GUI.
Capable of presenting *some* GUI, probably. Capable of running
currently-popular GUI applications, I'm not so sure. I've watched
what happens if Eclipse doesn't have enough memory. Not pretty.
You seem a bit quicker to dismiss people constrained to use
old equipment than I might have suspected given your oft-stated
objections to being asked to pay for (some) things. But maybe
"everyone" has enough money to buy a computer that will run your
applications of choice in a reasonable way, and they should be
using their money to *buy* one of these computers, rather than
for some other purpose. Whatever.
[ snip ]
--
B. L. Massingill
ObDisclaimer: I don't speak for my employers; they return the favor.
|
| |
|
| |
 |
Lew

|
Posted: 2007-10-16 20:50:00 |
Top |
java-programmer >> Great SWT Program
email***@***.com wrote:
> Then again, programming with an IDE rather obscures the
> fact that source code is plain text, converted to object code and
> then an executable with a compiler. But the department where
> I teach seems to focus more than some do on having students
> understand what's happening at a fairly low level. Whether in
> the long run that's better or worse than focusing solely, or
> almost solely, on something higher-level .... I don't know.
IDEs are not meant to substitute for text mode, which I'll call "command-line
mode". They can obscure knowledge, just like use of Struts can obscure
knowledge of the Model-View-Controller paradigm, or use of java.io can obscure
knowledge of low-level file I/O. They are meant to /supplement/ command-line
mode, and make certain tasks (not all tasks) more efficient for the programmer.
The nightly build-and-test cycle should not rely on an IDE, but occur via Ant,
a good version-control system and command-line tools like javac. IDEs
introduce dependencies on specific workstations, which is why you can't always
transfer entire workspaces between computers. (That one should never do
anyway - use the version control to do that.) They also introduce
dependencies on their internal build tools, which is why it takes some work to
build a project via Ant once you've locked yourself into the IDE's way of
doing things.
If your build cycle doesn't depend on any one IDE, then your team needn't
either. Practitioners can use, or even switch between, their vims and their
Eclipses, or their emaxen and their NetBeansies, or their JEdits and their
JBuilders, or whatever.
--
Lew
|
| |
|
| |
 |
Lew

|
Posted: 2007-10-16 20:51:00 |
Top |
java-programmer >> Great SWT Program
email***@***.com wrote:
> Actually, it might be, depending on what you mean by "straight
> vanilla listing of files". Just typing "ls" in a vanilla account
> on a Fedora 7 system to which I have access gives a list of files
> and directories in which different colors are used for different
> kinds of files. Device files appear in a different color from
> other kinds of files. <shrug>
That's the magic of .dircolors and LS_COLORS.
--
Lew
|
| |
|
| |
 |
Lew

|
Posted: 2007-10-16 20:55:00 |
Top |
java-programmer >> Great SWT Program
email***@***.com wrote:
> No. There's no conscious thought involved, any more than there's
> conscious thought involved in figuring out which of the car's
> pedals to push. Well, unless I've recently had the misfortune
> to have had to edit text with some other tool. It's a bit like
> trying to switch back and forth between a car with an automatic
> transmission and one with a clutch -- when I was more accustomed to
> the latter, sometimes I got a big surprise pressing the leftmost
> pedal in, um, a "normal" car. (Go ahead -- tell me that just
> proves again how much better an automatic is, since it's what
> "everyone" drives.)
It's a good analogy. Automatic transmissions are more convenient, but a
standard transmission gives you better fuel economy, better control of the
vehicle and more safety, if you're trained to use it.
--
Lew
|
| |
|
| |
 |
RedGrittyBrick

|
Posted: 2007-10-16 21:51:00 |
Top |
java-programmer >> Great SWT Program
email***@***.com wrote:
> On Oct 14, 8:11 pm, Arne Vajh鴍 <email***@***.com> wrote:
>
>> a european go down to his bank and get that bak to give him a Visa
>> or Mastercard and then he (or she) goes home and start ordering
>> from US web sites. As simple as that. No need to bring card back
>> from US.
>
>
> Those are American credit cards, from American companies.
No, he's referring to European cards from European companies.
European banks issue MasterCard or Visa affiliated Credit and Debit
cards that can be used in most places in the world, including the US,
either in person or online. I've *never* had a problem buying from US
sellers online.
In addition to (or instead of) "normal" credit and debit cards, Most
Europeans with a bank account can purchase a card with a fixed preset
balance (e.g. EUR 100) that is valid for a year, at which time any
remaining balance can be transferred back into your bank account. In the
meantime the card can be used for any number of online purchases up to
the card's remaining balance - this is exactly what it is designed for.
The bank I use refers to these as "gift cards" but they are Visa or
MasterCard affiliated and, in my experience, can be used anywhere that
accepts Visa or MasterCard.
I find it inconceivable that major Canadian banks don't offer similar
products to their customers ... GIYF ... They do - see below for one
example.
https://www.citizensbank.ca/Personal/Products/VISACards/VISAGiftCard/
"the Citizens Bank Visa gift card can be used wherever Visa is accepted
anywhere in the world, while enjoying all the convenience and security
of Visa."
"You can buy the Citizens Bank Visa gift card by calling us directly at
1-800-611-8472."
|
| |
|
| |
 |
blmblm

|
Posted: 2007-10-16 22:22:00 |
Top |
java-programmer >> Great SWT Program
In article <email***@***.com>,
Lew <email***@***.com> wrote:
> email***@***.com wrote:
> > Actually, it might be, depending on what you mean by "straight
> > vanilla listing of files". Just typing "ls" in a vanilla account
> > on a Fedora 7 system to which I have access gives a list of files
> > and directories in which different colors are used for different
> > kinds of files. Device files appear in a different color from
> > other kinds of files. <shrug>
>
> That's the magic of .dircolors and LS_COLORS.
Cool -- I just learned something else new. (Did you really mean
to put that dot before "dircolors"?)
(Must .... resist .... temptation to play with this to solve the
problem of some of the default colors not showing up nicely on a
dark background.)
--
B. L. Massingill
ObDisclaimer: I don't speak for my employers; they return the favor.
|
| |
|
| |
 |
blmblm

|
Posted: 2007-10-16 22:25:00 |
Top |
java-programmer >> Great SWT Program
In article <email***@***.com>,
Lew <email***@***.com> wrote:
> email***@***.com wrote:
> > No. There's no conscious thought involved, any more than there's
> > conscious thought involved in figuring out which of the car's
> > pedals to push. Well, unless I've recently had the misfortune
> > to have had to edit text with some other tool. It's a bit like
> > trying to switch back and forth between a car with an automatic
> > transmission and one with a clutch -- when I was more accustomed to
> > the latter, sometimes I got a big surprise pressing the leftmost
> > pedal in, um, a "normal" car. (Go ahead -- tell me that just
> > proves again how much better an automatic is, since it's what
> > "everyone" drives.)
>
> It's a good analogy. Automatic transmissions are more convenient, but a
> standard transmission gives you better fuel economy, better control of the
> vehicle and more safety, if you're trained to use it.
>
Not to spoil things, but I hear that automatic transmissions these
days can get fuel economy as good as, or nearly as good as, one can
get with a standard.
But in both cases, the "more trouble, more control" way has a
certain appeal for some of us. Part of it may be a snob factor,
but hey, some days one takes one's ego boosts where one can find
them?
--
B. L. Massingill
ObDisclaimer: I don't speak for my employers; they return the favor.
|
| |
|
| |
 |
nebulous99

|
Posted: 2007-10-18 17:28:00 |
Top |
java-programmer >> Great SWT Program
On Oct 15, 7:26 pm, Patricia Shanahan <email***@***.com> wrote:
> email***@***.com wrote:
> > On Oct 15, 4:41 pm, Roger Lindsj?<email***@***.com> wrote:
> >> I have an account with Swedbank (www.swedbank.se). I can get a new
> >> one-time credit card number with a fixed amount and expiry date in just
> >> a few seconds.
>
> > It's the time spent traveling and waiting in line, rather than the
> > time spent actually performing your transaction once you get to the
> > head of the queue, that would be prohibitive.
>
> You seem to be assuming the transaction requires a visit to a bank. Why?
Because it does. At least where I am, opening a new account (however
temporary) requires paperwork and definitely cannot be done at, say,
an ATM.
|
| |
|
| |
 |
nebulous99

|
Posted: 2007-10-18 17:45:00 |
Top |
java-programmer >> Great SWT Program
On Oct 15, 7:32 pm, email***@***.com (Bent C Dalager) wrote:
> What tutoring I received in emacs, I received for free from experts in
> the field.
Good for you! But that is a luxury unavailable to the bulk of the
population. Software that depends on such an uncommon luxury is
essentially for all intents and purposes unusable.
> >Fact 2: The ones you can learn to use unassisted but only by
> >struggling will still lose out in comparison with ones that are more
> >natural and easy to learn, in particular those that actually adhere to
> >de-facto standards like CUA.
>
> Only if the easier to learn apps compete in efficiency with the
> high-threshold ones. Often enough, they do not.
I explained in detail elsethread why this purported efficiency for
people proficient with emacs must be a myth. Nothing can be done
faster with it, and some things can be done faster with at least one
GUI editor, assuming proficiency with both editors.
The psychological cause is similar to that for the widespread
perception that using the mouse is slower for operations where
stopwatch measurements prove it's faster: people perceive less time
passing when typing than when reaching for another object, thinking
about their task, and the like. An emacs user will spend more time
typing in a given day, reducing the time they spend on things that
"feel" like they take longer, and come up with a high-biased estimate
of their task speed. So will someone who eschews the use of the mouse,
for similar reasons. Stopwatch measurements tell a different tale:
users of a modern GUI tool that are proficient in its use and that use
the mouse where appropriate are fastest.
> People who do not have the necessary spare time to learn efficient
> tool use are in for a world of hurt. You touch upon the consequences
> of this several times in your post so I do not find it necessary to
> enumerate them all over again.
You seem to assume two things here:
1. That tools like emacs are somehow superior in efficiency-of-use for
the proficient, a claim that has no supporting evidence except your
personal attestation, which isn't worth much TBH, and that does have
strong arguments and evidence AGAINST it.
2. Even granting the suspect claim of efficiency, you assume that this
magical extra efficiency cannot ever coexist with a shallow learning
curve such that an application could be written that a normal human
being can learn as they go with immediate productivity that rises over
time to eventually equal that of someone proficient with emacs. This
is an even dodgier claim, again with no supporting evidence and plenty
of evidence and cogent arguments against it.
Find evidence -- REAL evidence, not just anecdotes or "a feeling" you
have -- to support BOTH of the assumptions you've been making, or give
it up please.
> >There is simply no point in wasting weeks tearing out my hair trying
> >to make some old text-terminal-oriented software do something useful
> >when I can do everything I could potentially do with it right now,
> >with easier-to-use software.
>
> I certainly wouldn't advise tearing out your hair. This is likely to
> have negative medical consequences that would seriously hamper your
> learning curve.
You seem to assume it would not be an involuntary response. :P
> I agree with that when it is based on the assumption of someone not
> having the necessary time to train themselves in their profession.
This is a very interesting example of some fallacy or another whose
name I forget. Equivocation, perhaps? Regardless you suddenly changed
from talking about taking the time to "train themselves in emacs" to
taking the time to "train themselves in their profession". I'm not
aware that emacs constitutes a profession. If it does, then it's a sad
statement about the world. Nor is there any profession for which emacs
is an essential tool, at least so far as I am aware. It certainly
isn't essential to computer programming, system administration, or any
other IT job I'm aware of -- people in such jobs use a variety of
editors and IDEs and a large number do not use emacs, yet are
reasonably successful in their careers.
> I would much rather use one week with emacs to get the report out than
> use two weeks with notepad. Luckily, my already completed training
> buys me this option.
Why exactly would it take two weeks with notepad? What feature do you
need to speed up the job that notepad lacks? If it's mail merge or
almost any other similar "office" functionality, you want Word or
WordPerfect or Writer instead of notepad. If it's coding, you want a
proper IDE instead of just a text editor. And so forth.
> >Nothing about emacs is efficient (. . .)
>
> Seen from the perspective of someone who is not trained in it,
> possibly not. That's not where I am so that perspective holds no
> interest for me.
If you'd actually deigned to read the rest of what I wrote, you'd have
seen *mathematical proof* that emacs use cannot approach in some
specific tasks the efficiency of a modern GUI editor. In one case, the
only maths actually needed being the ability to count past ten. :P
Which is faster? One quick flick of the mouse, or hitting page up
about 300 times? You do the math.
> Emacs gives me all the help that I need when I want to use unfamiliar
> functionality, and I don't know how long it was since it got
> scrollbars. I am sure I have been using them in emacs since ~1990 when
> I first fired it up.
I don't know what you're talking about here, but it isn't emacs
running in a text terminal session. It might be some fork, or port of
emacs to a GUI environment, or something. And all that does is make
moving around a bit faster. All my other arguments stand even so.
> emacs is easy to use, it's just not easy to learn.
Anything that requires memorizing a list of disconnected and obscure
character sequences the size of a phone book to use is neither easy to
learn NOR easy to use.
> Why you would want
> to unplug your mouse whenever you launch emacs, I do not know.
??
> With the caveat that I am not sure how much, exactly, a zillion is -
> none of the above is an accurate description of my use of emacs.
If you have some magic emacs variant that behaves like a modern editor
in those respects, then you have an editor you can actually be as fast
with as a normal one. But still not faster, and slower to get started
with. That means emacs still loses. Sorry!
|
| |
|
| |
 |
| |
 |
Index ‹ java-programmer |
- Next
- 1
- insulting religion or discussing Java?email***@***.com <email***@***.com> wrote:
>> It's not "Newsflash, moron" it's: "Newsflash, mormon". Oh wait, is
>> there a difference?
Chris Smith wrote:
> Wow, what a jerk. I thought the original multiposting spammer was a
> jerk, but this takes the cake. Perhaps people can stop spamming AND
> stop insulting other people's religions, and get back to discussing
> Java.
I am a neo-Buddhist pantheistic Gnostic Goddess-worshipper. If that isn't
worthy of ridicule nothing is. (Or everything is.) I am also a very competent
Java programmer. Coincidence? You decide!
- Lew
neo-Buddhist pantheistic Gnostic Goddess-worshipper
(Gods! What a fool!)
- 2
- Java Compilers... I need get some good compiler but its hard 2 find it...So can some 1
give me link or good
compiler for java..
well I think google is my best friend.
email***@***.com
- 3
- cup dilemmaHi all,
I'm making a parser with java_cup and jlex, it must recognize a language
like this:
// Definition of the apparel heads:
dress = [quality->10, woven->8];
shirt = [quality->10, woven->8];
?
// Description of the apparel heads:
BOSSdress = quality *, woven -: dress;
dressofValentino = quality *, woven +: dress;
shirtofArmani = quality +, woven +: shirt;
The definition of the apparel heads is made with this cup code:
non terminal frasi, frase;
frasi ::= frasi frase | frase;
frase ::= LETTER:var EQ QO LETTER:attr ARROW NUMBER:n QC SEMI
{:
System.out.print("Ist: " + var);
System.out.print(" attrib: " + attr);
System.out.println(" value: " + n);
:};
Now I need recognize the second part of language, but how I can
distinguish by the '?' ?
JLex code:
%%
%cup
%%
";" { return new Symbol(sym.SEMI); }
"=" { return new Symbol(sym.EQ); }
"->" { return new Symbol(sym.ARROW); }
"[" { return new Symbol(sym.QO); }
"]" { return new Symbol(sym.QC); }
"?" { return new Symbol(sym.ASKP); }
[0-9]+ { return new Symbol(sym.NUMBER, new Integer(yytext())); }
[a-zA-Z]+ { return new Symbol(sym.LETTER, new String(yytext())); }
[ \t\r\n\f] { /* ignore white space. */ }
. { System.err.println("Illegal character: "+yytext()); }
Thanks in advance
- 4
- JNI string problemI have a JNI problem when calling native code from a java program. The
java program is passing in a non-empty String to the native code, but at
the native code level I crash out on a call to NewStringUTFChars using
the passed-in jstring. When I run with the -Xcheck:jni parameter, I get
the following output:
JVMCI161: FATAL ERROR in native method: JNI received a null string
at a.b.c.MyNativeMethod(Native Method)
(class + package names obscured)
So, it would appear that the jstring getting passed in is null in some
way. Question is, how can I examine this jstring object to see what's in
it? I've tried to find the definition of jstring without luck. Can
anyone help here?
thanks
alex
- 5
- Signing applet jar without verified digital IDI'm the admin of an open-source java project
(http://jugglinglab.sourceforge.net), and a rank newbie to the topic
of jar signing. I would like to be able to copy/paste text between my
applet and other applications, and from what I understand this
requires the applet to be trusted.
Now a verified digital ID from VeriSign seems to cost around $400,
which is way too much for an open-source project to consider. I'm
wondering if it's possible to create our own (unverified) ID and
self-signed certificate, and sign our jar with that. I have hunted
around and not seen any straightforward instructions on how to do
this, or even an indication of whether it's possible.
Can anyone clue me in here? Thanks for the help!
Jack
- 6
- New to Java - quick question on embedding in browserPlease take a look at www.seemethroughcollege.com/test.html
This applet was on this web site as soon as I took over the project. It is
taken originally from http://www.radinks.com/upload/ (full version).
Anyway, it seems to all work correctly apart from on case:
If the browser is Internet Explorer and Java is not installed, it does not
prompt you to download it, only displays a little 'x' like the object is
missing.
In FireFox it prompts you, and if Java is installed it works fine.
What can I add to the code so that users are prommpted to download the
applet?
(I did try codebase= which at first I thought worked, but then the applet
did not run
Thanks
- 7
- Cannot delete Se Development Kit from VistaHello,
I need to reinstall the JDK but the installer insists the development kit is
still installed, when I agree to re-installing it just stays in an endless
loop of telling me it is already installed and do I want to reinstall. I
have physically deleted all the java directories and last night paid 40
bucks for a registry cleaner that has made no difference.
When I try to delete using the uninstall utility in Vista it claims to
delete it by the Java SE Development Kit Update 2 reference stays there.
Does anyone know what I need to do to be able to get it re-installed?
Thanks,
Wayne
- 8
- CVS Resource History Date/Time is not availableSince the beginning of the new year, when I do a Show In Resource
History for any resource in CVS, it displays revision, tag, and other
information as normal; however, the Date field it displays "Not
Available". Does anyone know why? I am using Eclipse version 3.1.0
Many Thanks.
- 9
- 10
- Applet scanning another IP!Hi, i'm trying to scan from an applet other IP then the Server IP. But
i know that this is a restriction of the applet, because i can scan
only the Server IP. is there a methods to force this?
- 11
- 12
- Using relative path in java programs - how ?Hi
I wrote a new servlet that uses a configuration file to store
parameters.
The problem is that I want to use a relative path when accessing this
file, since I dont know where this servlet will be deployed.
Basically, I want it to be in the same directory where the .class
files are located.
Using the property user.dir does'nt help because it returns the
server's executable path.
How can I control this ? how can the program "know" where the class
files are ?
- 13
- Unable to Retrieve NUMBER from ResultSet.I'm having a problem returning a value from a ColumnType NUMBER in a
ResultSet. The result set is obtained from an Oracle database as
follows:
// CODE SNIP
java.sql.Connection connX =
com.ICMG.Utilities.DataAccess.DBODSConnection.getConnection("DEVELOPMENT");
java.sql.Date d = new java.sql.Date(2001, 1, 1);
String strOracleSyntaxFunctionQuery = "begin ? :=
PKSTATETAX.GETSTATETAXLIST(?, ?); end;";
java.sql.CallableStatement stmt =
connX.prepareCall(strOracleSyntaxFunctionQuery);
stmt.registerOutParameter(1, oracle.jdbc.OracleTypes.CURSOR);
stmt.setString(2, "PT");
stmt.setDate(3, d);
stmt.execute();
java.sql.ResultSet rs3 = (java.sql.ResultSet)stmt.getObject(1);
The result set returns the following fields:
STATECD, CHAR, 2
TAXTYPECD, VARCHAR2, 32
TAXRATE, NUMBER, 0
I'm reading the resultset as follows:
// CODE SNIP
while (rs3.next()) {
String strState = rs3.getString("STATECD");
String strTaxType = rs3.getString("TAXTYPECD");
float TaxRate = 000.000000F;
TaxRate = (float) rs3.getFloat("TAXRATE");
out.println("<TR>");
out.println("<TD WIDTH=\"5%\" VALIGN=\"TOP\"
ALIGN=\"LEFT\"> </TD>");
out.println("<TD VALIGN=\"TOP\" ALIGN=\"LEFT\">" + strState +
"</TD>");
out.println("<TD VALIGN=\"TOP\" ALIGN=\"LEFT\">" + strTaxType +
"</TD>");
out.println("<TD VALIGN=\"TOP\" ALIGN=\"LEFT\">" + TaxRate +
"</TD>");
out.println("<TD VALIGN=\"TOP\" ALIGN=\"LEFT\"></TD>");
out.println("</TR>");
}
My problem is that, while I am able to retrieve the String values
(STATECD AND TAXTYPECD), I am unable to retrieve the NUMBER field
TAXRATE. I've tried a getFloat (above), getLong(), getString()...
just about everything I can think of. If I try to getObject (any
object), it comes back null. When I do any of the other gets
(getLong, getFloat), I just get zero:
AK PT 0.0
AL PT 0.0
AR PT 0.0
AS PT 0.0
I know the Oracle function is working correctly, because running the
funciton in PL/SQL Developer returns:
AK PT 2.7
AL PT 2.3
AR PT 2.5
AS PT 1.75
Any help would be greatly appreciated. Thanks.
- 14
- eclipse exporting project having extarnal jars as libsHi there
i have done a java project on eclipse , i have used some extarnal jar
files as lib in my project added them by (right click on my project
folder --> properties --> java build path --> libraries --> add
external jars) i also checked on them in
(right click on my project folder --> properties --> java build path
--> order and export)
but when i export my project to executable jar file ( i get the file)
but cant run it
on double click it says (could not find main class) while i have
defined the correct main class in the exporting wizard,
i also tried to extract the jar file and didnt found any of my external
jar libs in it so how can i give this file to my users without making
them download the libs themselves
i need your help please
- 15
- JAR File ErrorDear All;
please help!
Let me explain you first about my problem
1- connectToMySqlJoke
------------------------------
import java.sql.*;
public class connectToMySqlJoke {
private String serverHost;
private String port;
private String userName;
private String password;
private String schema;
private Connection connection=null;
private Boolean connected;
public connectToMySqlJoke(){
this.serverHost="localhost";
this.port="3306";
this.userName="root";
this.password="123456";
this.schema="jokedb";
Connect();
}
public void Connect(){
String connStr = "";
try {
Class.forName("com.mysql.jdbc.Driver");
connStr="jdbc:mysql://"+ this.serverHost +":";
connStr+=this.port + "/" + this.schema;
connection =
DriverManager.getConnection(connStr,this.userName,this.password);
this.connected=true;
}
catch (SQLException e){
this.connected=false;
//System.out.println("Sql error");
}
catch (ClassNotFoundException e){
this.connected=false;
//System.out.println("jdbc driver not found!");
}
}
public Connection getConncetion() {
return connection;
}
public void closeConnection(){
try {
connection.close();
}
catch (Exception e){}
}
public Boolean IsConnected(){
return this.connected;
}
}
2- TestConnection
---------------------
public class TestConnection {
public static void main(String[] args) {
connectToMySqlJoke mycnt=new connectToMySqlJoke();
System.out.print(mycnt.IsConnected());
}
}
Yes, it works after i compile it and it returns TRUE. it connects.
But after i make JAR file. it do not work. i wonder why?
I make like this:
My mainClass file contain: Main-Class: TestConnection
jar cmf mainClass Test.jar *.class
then i run
java -jar Test.jar
it return false
help help
|
|
|