Search Result

Collapse
5 results in 0.0042 seconds.
Keywords
Members
Tags
methods
  •  

  • shockna1
    started a topic Sharing variables and methods between classes

    Sharing variables and methods between classes

    I have recently come across a situation where various non-related class need to share variables and methods. The first thing that came to my mind was to make a static class with static variables and methods which works fine, but I was wondering if there was a more OO way of doing this. Thanks in advance!
    See more | Go to post

  • Mary Seelye
    started a topic How to turn this to mirror BACK to FRONT
    in Java

    How to turn this to mirror BACK to FRONT

    This method mirrors FRONT to BACK and now I need it to go BACK to FRONT:

    public void mirrorFrontToBa ck()
    {
    int length = this.getLength( ); //save the length
    int mirrorPoint = length / 2; //mirror around this
    int value = 0; //hold the current value
    //loop from 0 to mirrorPoint
    for (int i=0; i < mirrorPoint; i++) {
    value = this.getSampleV alueAt(i);
    ...
    See more | Go to post

  • wivked
    started a topic Parameter problem

    Parameter problem

    Hi all,

    I have this problem,

    I want to return certain value's from a method.
    And that method has a parameter.

    And i want to use that return value in a
    other method, but it i dont have the
    correct parameters for the method.

    Example.
    Code:
     
    
    
     private void button1_Click(object sender, EventArgs e)
     {
     click(e);
     
     }
    ...
    See more | Go to post

  • Daniel101
    started a topic Passing a Method?
    in Java

    Passing a Method?

    Hello, I'm still new to Java and I have a certain problem in my code.

    I've made 2 classes (Person and Group) and 1 demo (Which is used for testing my classes).

    Person works perfectly fine when I use it along with my demo.
    Though, I'm having a bit of trouble importing/using certain methods from Person in Group.
    The problem is that I do not know how to import/use a method from another class in my Group class...
    See more | Go to post

  • nickburton
    started a topic Methods without creating an object?
    in Java

    Methods without creating an object?

    Hi there, I am new to Java and the concept of requiring a class/object to do everything..

    I am creating a menu based program and hence need to re-use segments of code. If I was writing in C, I would just create a method above the main program and then call that method each time I wanted to, for example, display a menu.

    The program I'm writing has two main classes from which I create objects to store data (imagine a 2D...
    See more | Go to post
Working...