Click here to Skip to main content
16,016,394 members
Home / Discussions / Java
   

Java

 
AnswerRe: plz help in java question Pin
427748024-Sep-09 3:37
427748024-Sep-09 3:37 
QuestionLUCKY DRAW system Pin
syarizan23-Sep-09 23:03
syarizan23-Sep-09 23:03 
AnswerRe: LUCKY DRAW system Pin
Richard MacCutchan24-Sep-09 1:22
mveRichard MacCutchan24-Sep-09 1:22 
AnswerRe: LUCKY DRAW system Pin
427748024-Sep-09 2:58
427748024-Sep-09 2:58 
QuestionProblems Implementing Functions into Main.java Pin
wkid8722-Sep-09 17:42
wkid8722-Sep-09 17:42 
AnswerRe: Problems Implementing Functions into Main.java Pin
David Skelly22-Sep-09 22:21
David Skelly22-Sep-09 22:21 
AnswerRe: Problems Implementing Functions into Main.java Pin
Richard MacCutchan22-Sep-09 23:05
mveRichard MacCutchan22-Sep-09 23:05 
GeneralRe: Problems Implementing Functions into Main.java Pin
wkid8723-Sep-09 3:50
wkid8723-Sep-09 3:50 
Sorry, I'm double post the Function.java code Below is my Linear Function.java.


<br />
/*<br />
 * To change this template, choose Tools | Templates<br />
 * and open the template in the editor.<br />
 */<br />
<br />
package Function;<br />
<br />
/**<br />
 *<br />
 * @author aaron's<br />
 */<br />
public class LinearFunction implements Function{<br />
     private double slope = 1.0;<br />
     private double yIntercept = 0.0;<br />
<br />
     public double getSlope(){<br />
         return slope;<br />
     }<br />
<br />
     public void setSlope(double s){<br />
         slope = s;<br />
     }<br />
<br />
     public double getYIntercept(){<br />
          return yIntercept;<br />
     }<br />
<br />
     public void setYIntercept(double y){<br />
         yIntercept = y;<br />
     }<br />
     public double getValue(double inValue){<br />
         return slope+inValue+yIntercept;<br />
     }<br />
<br />
}<br />
<br />


I will like for all the methods that are in the LinearFunction.java to load in Main.java. The only methods that is loading up correctly is get.Value. There is an error in my Main.java file using setSlop and getSlope. I'm new to Java and I hope this information help.
GeneralRe: Problems Implementing Functions into Main.java Pin
Richard MacCutchan23-Sep-09 5:43
mveRichard MacCutchan23-Sep-09 5:43 
GeneralRe: Problems Implementing Functions into Main.java Pin
David Skelly23-Sep-09 6:24
David Skelly23-Sep-09 6:24 
GeneralRe: Problems Implementing Functions into Main.java [modified] Pin
wkid8723-Sep-09 16:59
wkid8723-Sep-09 16:59 
GeneralRe: Problems Implementing Functions into Main.java Pin
David Skelly24-Sep-09 3:35
David Skelly24-Sep-09 3:35 
AnswerRe: Problems Implementing Functions into Main.java Pin
427748023-Sep-09 18:22
427748023-Sep-09 18:22 
QuestionN Queens Problem help Pin
shiggedyshwa21-Sep-09 19:20
shiggedyshwa21-Sep-09 19:20 
AnswerRe: N Queens Problem help Pin
427748021-Sep-09 20:27
427748021-Sep-09 20:27 
GeneralRe: N Queens Problem help Pin
shiggedyshwa21-Sep-09 21:15
shiggedyshwa21-Sep-09 21:15 
QuestionRead a file and find text Pin
Mbu00720-Sep-09 22:28
Mbu00720-Sep-09 22:28 
AnswerRe: Read a file and find text Pin
427748021-Sep-09 4:31
427748021-Sep-09 4:31 
QuestionHow do i get all values from a JTextfields that is located on another JInternalFrame? Pin
miceisland20-Sep-09 20:36
miceisland20-Sep-09 20:36 
AnswerRe: How do i get all values from a JTextfields that is located on another JInternalFrame? Pin
427748021-Sep-09 4:37
427748021-Sep-09 4:37 
QuestionHaving trouble with recursion (kind of long, but please read) Pin
KingLane20-Sep-09 12:48
KingLane20-Sep-09 12:48 
AnswerI got the code to work Pin
KingLane20-Sep-09 14:06
KingLane20-Sep-09 14:06 
QuestionJava projects Pin
prietycool19-Sep-09 0:29
prietycool19-Sep-09 0:29 
AnswerRe: Java projects Pin
Richard MacCutchan20-Sep-09 9:29
mveRichard MacCutchan20-Sep-09 9:29 
QuestionJava web Project using Springs Pin
prietycool19-Sep-09 0:27
prietycool19-Sep-09 0:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.