When to make a different class

I am just getting started doing programming in general and one thing i dont get is when you make different classes and why any code or tutorials would help alot.

ok thanks for the tutorials. can you give like the names of the classes i would need to make a pong game and an outline of what should go in there e.g. class: player paddle controls for movement detecting when the ball hits ect.

Similar Messages

  • On my iPhone 4, people cant hear me when I make and / or receive normal (GSM) phone calls. But when on calls using internet based / native apps like viber or skype, people can hear me just fine. Voice memos work too and have already tried different SIMs

    On my iPhone 4, people cant hear me when I make and / or receive normal (GSM) phone calls. But when I make/receive calls using internet-based / native apps like viber or skype, people can hear me just fine. I have tried recording my voice using voice memos - this works. And have already tried different SIM cards but the problem persists.
    I have taken my phone to an authorized Apple service center, where they restored my phone to factory settings, but still facing the same issue. They service center directed me to Apple Customer Care Hotline, where I have now spent 3+ hours explaining my issue and yet no one can resolve it. The easy answer if to replace the phone - and since it is out of warranty, I am expected to pay for it.
    Additionally, the customer service has been so rude and confrontational that it has completely changed my view of Apple and its customer focus. I am a disappointed and angry customer today - people would be surprised to hear just how rude customer service was including making statements such as "Apple doesnt make infallible products, that's why warranty is needed for our products" and that "every product undergoes a problem at some stage, so do ours!" There goes whatever confidence I had...
    My concern is simple - if no one at Apple and / or its CS hotline is able to address my issue comprhensively and keep telling me that they have never encountered a precedent before, then with what right can they expect me to pay for a replacement?! I am NOT here to fund Apple's research into their product faults and manufacturing.
    And even though a customer is out of warranty, is it too much to expect an Apple product to work well for at least a 'reasonable' period of time. My phone is less than 18 months old and has been facing this issue for the past 2 months - surely the longevity of Apple products is more than 18 months!
    Just a sad sad day for an Apple customer, compounded by unjustifiably rude and aggressive staff. And still no resolution to my problem.

    I am having the same issue - with my last 2 iPhone 4's. My first handset each time I was on a call wether it was up to my ear or on loud speaker, the call would automatically mute even though the mute button wouldn't show up as highlighted. Pressing the mute button on and off during the call doesn't fix it either. I rang Apple and asked what some of their trouble shooting solutions were. I got told that it might be a software issue and to install the latest software update. This failed. I then got told to uninstall the software on the phone and do a complete restore. This also failed. After trying the troubleshooting suggestions, I took the phone into my provider and they sent me out a new phone within a week under warranty claiming it was a hardware issue and probably just a "glitch" with that particular phone. This was not the case....
    After receiving my second iPhone 4, I was hopeful that it would work. For the first couple of days, making/receiving calls was not an issue. Until after about a week, the same problem started again. In one instance I had to hang up and call back 4 times and the call would still automatically mute after about 5 seconds. Also on the second handset, the main camera located on the back of the phone has red and blue lines running through it and can't take a decent picture. So back to the store I go to get another replacement - Again.
    For a phone that is rated highly and as a keen Apple product purchaser, I am a bit disappointed with the experience I have had with the iPhone 4. Let's hope they find a fix sometime soon because this is becoming a bit beyond a joke.....!!

  • When it's required to share a single object in different classes????

    Hi friends...
    I am new to java programming language....
    when it is required to share a single object in different classes???
    and
    please give me one example with explanation...
    Thank you
    regards Shree

    sun_shree wrote:
    Thanks for all giving reply.....
    please write the constructor which is accepting reference and please,,,,,, explain......
    Thanking youNo.
    This will be covered in any Java textbook or tutorial. Like this one: [http://java.sun.com/docs/books/tutorial/java/javaOO/arguments.html]
    After reading it and writing some code of your own to test your understanding, if you still have a specific question, post again.

  • HT201406 when i make a video then is screen show different colour and they didn't make a video good? i m using a iphone 5.

    when i make a video then is screen show different colour and they didn't make a video good? i m using a iphone 5. plz give me good advise... I buy this mobile two month ago...

    Cannot recall the full line-up of Effects in Pr 6.5, but you should have the fixed Effect>Motion>Scale, which will allow you to resize the Clip. You might need to use Motion>Position in addition. Basically, you will doing a PiP (Picture in Picture), with no Clip below, just the black showing.
    Good luck,
    Hunt

  • How to make versionable object of different class than Document?

    In the programmers reference is that every PublicObject can be versioned, but there are only samples for versioning documents. I would like to keep history on folder hierarchy changes, so I think I need a Folder that can be versioned.
    The question is how to do this?
    Should I override isVersionable method in subclass of Folder to return true?
    Please help

    Hi
    I am havin 10 text boxes in my application.
    But out of 10 , 3 will be always together(existence of one is not possible without the other two.)
    Now i want to create a vector of objects ( here object will consist of the value corresponding to these three boxes),there can be many elements in this vector.
    So i m thinking to make an inner class which have three String variables corresponding to these text boxes that exists together.
    What can b done ?

  • Use two different classes

    Hi ,thanks a lot for reading this.
    I would like to create a java class which can perform addition ,namely this program should return the sum of two integers.
    Then another java class should use the previous one in order to add couples of integers.
    I know how I should do it if I had the function that performs the addition in the same *.java file but how can I make it work when there are two different files that the one should use the other?
    Thanks in advance
    Dennis

    So you have class someClass that might look like
    public class someClass
        public int sum(int a, int b)
             return a+b;
    }you'd then have a class otherClass that could use A such as
    public class otherClass
         public void foo()
             someClass test = new someClass   //create and instantiate your class with a variable name
             int x = test.sum(5, 2);   //use your variable name to call the method.

  • Updating JPanel with buttons from a different class

    I have a JPanel in a class that has a gridlayout with buttons in it for a game board. And my problem is that when I want to update a button using setIcon() the button doesn't change in the GUI because the buttons are in a different class. The JPanel is in a Client class and the buttons are in a GamePlugin class. I've tried a bunch of different things but none of them worked or it was way too slow. I'm sure theres an easy way to do it that I'm not seeing. Any suggestions? Heres part of my code for updating the GUI.
    private JPanel boardPanel = new JPanel(); 
    Container cP = getContentPane();
    cP.add(boardPanel, BorderLayout.WEST);
    boardPanel.setPreferredSize(new Dimension(400, 400));
    boardPanel.setLayout(new GridLayout(8, 8));
    cP.add(optionsPanel, BorderLayout.CENTER);
          * Gets the board panel from the selected plugin.
         public void drawGameBoard(GamePlugin plugin) {
              board = (OthelloPlugin)plugin;
              boardPanel = board.getBoardPanel();
              for (int i = 0; i < GamePlugin.BOARD_SIZE; i++)
                   for (int j = 0; j < GamePlugin.BOARD_SIZE; j++) {
                        board.boardButtons[i][j].setActionCommand("" + i + "" + j);
                        board.boardButtons[i][j].addActionListener(this);
          * This method takes a GameBoard and uses it to update this class' data
          * and GUI representation of the board.
         public void updateBoard(GamePlugin updatedBoard) {
              board = (OthelloPlugin)updatedBoard;
              for (int i = 0; i < GamePlugin.BOARD_SIZE; i++) {
                   for (int j = 0; j < GamePlugin.BOARD_SIZE; j++) {
                        int cell = board.getCell(i,j);
                        if (cell == OthelloPlugin.PLAYER1){
                             board.boardButtons[i][j].setIcon(black);
                        else if (cell == OthelloPlugin.PLAYER2)
                             board.boardButtons[i][j].setIcon(white);
                        else
                             board.boardButtons[i][j].setText("");
         }

    txp200:
    I agree that a call to validate() , possibly repaint(), should fix your problem. In the class with the panel that the buttons are on, i would create a static repaint method that call panel.repaint(). You can then call that method in your other class. Just make sure u only use methods to change the properties of the button, never make a make a new one, as then you will lose the association with the panel. Hope this helps.
    -- Brady E

  • Different classes problems

    I posted a topic asking for feedback on a Vigenere Cipher program I made. It was said that I shouldn't have the entire program in one class, and should have different class... or methods?
    I've been reading the tutorial for different classes, but I just can't seem to pick it up. I anticipate I'm gonna get a few replies with people saying 'you should read this smelly student' but I've tried, so I figure this may be a way to break me in :).
    So, here's my code:
    public class VigenereCipherComplete
         public static void main(String[] args)
         String key, message;
         String encrMessage = "";
         String[] options = new String[] {"Encrypter", "Decrypter", "Cancel"};
         int progChoice, keyLength, length, encrCharValue;
         int index;
         int keyIndex = 0;
         char keyChar;
         char messageChar;
         char encrChar;
         boolean shouldEncrypt = true;
         // Choice of whether to use the encrypter of decrypter
            progChoice = JOptionPane.showOptionDialog(null, "Which would you like to run?", "Program choice",
                 JOptionPane.DEFAULT_OPTION, JOptionPane.QUESTION_MESSAGE, null, options, options[0]);
            if(progChoice == 0)
                 shouldEncrypt = true;
            else if(progChoice == 1)
                shouldEncrypt = false;
        else
           System.exit(0);
         // Input of key and converting it to upper case
         key = JOptionPane.showInputDialog(null, "Please input the key you wish to use:",
              "Key input", JOptionPane.QUESTION_MESSAGE);
         key = key.toUpperCase();
         // Input of message and converting it to upper case
         message = JOptionPane.showInputDialog(null, "Please input the plaintext you wish to use:",
              "Plaintext input", JOptionPane.QUESTION_MESSAGE);
         message = message.toUpperCase();     
         keyLength = key.length();
         length = message.length();
         // Encryption/decryption
         for(index = 0; index < length; index++)
              keyChar = key.charAt(keyIndex);
              messageChar = message.charAt(index);
              if(messageChar >= 'A' && messageChar <= 'Z')
                   // Encryption
                   if(shouldEncrypt)     
                        encrCharValue = (keyChar - 'A') + messageChar;
                   // Decryption
                   else
                        if(messageChar >= keyChar)
                             encrCharValue = (messageChar + 'A') - keyChar;
                        else
                             encrCharValue = ((('Z' - keyChar) + messageChar) + 1);
                   // Loops ascii char value larger than 90 so it stays within the 65-90 ascii char range
                   if(encrCharValue > 'Z')
                        encrCharValue = (encrCharValue - 'Z') + 'A' - 1;
                   // Converts the char value to a char and adds it to the converted string
                   encrChar = (char)encrCharValue;
                   encrMessage = encrMessage + encrChar;
                   keyIndex++;     
              // If the char is not a letter, it leaves it as it is and adds it to the converted string     
              else
                   encrCharValue = messageChar;
                   encrChar = (char)encrCharValue;
                   encrMessage = encrMessage + encrChar;
              // Resets key so it will loop for the full string wanting to be converted
              if (keyIndex >= keyLength)
                   keyIndex = 0;
         // Output for encryption
         if(shouldEncrypt)
              System.out.println("Plaintext:\t" + message + "\nKey:\t\t" + key + "\nCiphertext:\t" + encrMessage);
         // Outfor for decryption
         else
              System.out.println("Ciphertext:\t" + message + "\nKey:\t\t" + key + "\nPlaintext:\t" + encrMessage);
    }I just can't grasp how I'd do this... Sorry for the ambigious question.

    I'm not going to read all your code. However, it's reasonable to put the code for one encryption algorithm into one class. If you were writing an entire encryption library, you might find that several of your algorithms (each in their own class) are all using the same code, and you're copying it from one class to another. In this case, you might extract that common code out to a utility class that various algorithms make use of.
    Now, if we assume that your question is, "How can I break this code into smaller pieces?" here are a few suggestions, based on a cursory skimming of your code. Note that these are only guidelines, to give you an idea of the kinds of things that make sense to break out as pieces.
    1. Keep the GUI separate from the encryption. You should have a VigenereEncryption or somesuch class that actually does the work of encrypting and decrypting, and this class should not know or care if there even is a GUI.
    2. In the VE class, I would imagine you'd want an encrypt() method and a decrypt() method.
    3. Anywhere you see multiple levels of nesting, one or more of those levels might be a candidate to pull out into its own method.
    4. Anywhere you have repeated code that's more than a couple lines, put it in its own method.
    5. Anywhere you have a comment like // perform such and such step above a block of code, that block is a good candidate to get pulled out into its own method, named similar to whatever that step is in your comments.
    6. Similarly, when you learn what the high-level algorithm is that you're to be implementing, the steps of that algorithm are candidates to be their own methods.
    Again, note that this is not carved in stone and is not meant to be taken literally as "do exactly all of these things." Rather, it is to give you ideas about the kinds of things that make for separation of classes and methods.

  • Two equal objects, but different classes?

    When programming on binding Referenceable object with JDK version 1.5.0_06, I have encountered a very strange phenomenon: two objects are equal, but they belong to different classes!!!
    The source codes of the program bind_ref.java are listed as below:
    +++++++++++++++++++++++++++++++++++++++++++++++++++++++
    import java.lang.*;
    import java.io.*;
    import java.util.*;
    import javax.naming.*;
    import javax.naming.spi.ObjectFactory;
    import java.util.Hashtable;
    public class bind_ref {
    public static void main( String[] args ) {
    // Set up environment for creating the initial context
    Hashtable env = new Hashtable();
    env.put( Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.fscontext.RefFSContextFactory" );
    env.put( Context.PROVIDER_URL, "file:/daniel/" );
    Context ctx = null;
    File f = null;
    Fruit fruit1 = null, fruit2 = null;
    byte [] b = new byte[10];
    try {
    ctx = new InitialContext( env );
    Hashtable the_env = ctx.getEnvironment();
    Object [] keys = the_env.keySet().toArray();
    int key_sz = keys.length;
    fruit1 = new Fruit( "Orange" );
         SubReference ref1 = fruit1.getReference();
    ctx.rebind( "reference", fruit1 );
         fruit2 = ( Fruit )ctx.lookup( "reference" );
         System.out.println( "ref1's class = (" + ref1.getClass().toString() + ")" );
         System.out.println( "fruit2.myRef's class = (" + fruit2.myRef.getClass().toString() + ")" );
         System.out.println( "( ref1 instanceof SubReference ) = " + ( ref1 instanceof SubReference ) );
         System.out.println( "( fruit2.myRef instanceof SubReference ) = " + ( fruit2.myRef instanceof SubReference ) );
         System.out.println( "ref1.hashCode = " + ref1.hashCode() + ", fruit2.myRef.hashCode = " + fruit2.myRef.hashCode() );
         System.out.println( "ref1.equals( fruit2.myRef ) = " + ref1.equals( fruit2.myRef ) );
    } catch( Exception ne ) {
    System.err.println( "Exception: " + ne.toString() );
    System.exit( -1 );
    +++++++++++++++++++++++++++++++++++++++++++++++++++++++
    All the outputs are shown as below:
    =======================================================
    Fruit: I am created at Mon Jun 18 11:35:13 GMT+08:00 2007
    SubReference: I am created at Mon Jun 18 11:35:13 GMT+08:00 2007
    --------- (i)subref.hashCode() = (-1759114666)
    SubReference: I am created at Mon Jun 18 11:35:13 GMT+08:00 2007
    --------- (i)subref.hashCode() = (-1759114666)
    FruitFactory: obj's class = (class javax.naming.Reference)
    FruitFactory: obj's hashCode = -1759114666
    FruitFactory: obj = (Reference Class Name: Fruit
    Type: fruit
    Content: Orange
    FruitFactory: ( obj instanceof SubReference ) = false
    FruitFactory: subref_class_name = (Fruit)
    Fruit: I am created at Mon Jun 18 11:35:13 GMT+08:00 2007
    ref1's class = (class SubReference)
    fruit2.myRef's class = (class javax.naming.Reference)
    ( ref1 instanceof SubReference ) = true
    ( fruit2.myRef instanceof SubReference ) = false
    ref1.hashCode = -1759114666, fruit2.myRef.hashCode = -1759114666
    ref1.equals( fruit2.myRef ) = true
    ========================================================
    I hightlight the critical codes and outputs related to the strangeness with bold texts.
    Who can tell me what happens? Is it really possible that two objects belonging to different classes are equal? If so, why that?

    It can also depend on how you implement the equals method.
    class Cat {
        String name;
        Cat(String n) {
            name = n;
    class Dog {
        String name;
        Dog(String n) {
            name = n;
        public boolean equals(Object o) {
            return name.equals(o.name);
        public static void main(String[] args) {
            Dog d = new Dog("Fred");
            Cat c = new Cat("Fred");
            System.out.println(d.equals(c));
    }

  • Can't call or execute of different class files in a main program

    Hi, I got a main program which can call 3 different classes. The main program have an implicit-choice List as a starting menu. If one of the file is selected, the files will call out and display it. However, i managed to call the 1st 2 files, and the 3rd files can't display anything after selected.
    I enclosed my code as below:
    import javax.microedition.midlet.*;
    import javax.microedition.lcdui.*;
    public class Catalogues extends Form implements CommandListener {
         private Displayable parent;
         private Display display;
         private List Cata;
         private Boots bo;
         private Higheels hHeels;
         private Sandals sand;
         private Slippers sp;
        private Command backCommand = new Command("Back", Command.BACK, 1);
        private Command viewCommand = new Command("View", Command.SCREEN, 1);
        private String[] options = {"Boots", "High Heels","Sandals", "Slippers"};
         public Catalogues(Display d, Displayable p) {
              super("Welcome to Footwear World");
              Cata = new List("Select Option", List.IMPLICIT, options, null);
              display = d;
            parent = p;
              addCommand(backCommand);
              addCommand(viewCommand);
              setCommandListener(this);
         public void commandAction(Command c, Displayable d) {
         if(d==parent && c==List.SELECT_COMMAND){
              switch(parent.getSelectedIndex()){
                   case 0:
                           if(bo==null){
                              bo = new Boots(display,parent);
                             display.setCurrent(bo);
                              break;
                   case 1:
                           if(hHeels==null){
                              hHeels = new Higheels(display,parent);
                             display.setCurrent(hHeels);
                              break;
                   case 2:
                           if(sand==null){
                              sand = new Sandals(display,parent);
                             display.setCurrent(sand);
                              break;
                   case 3:
                           if(sp==null){
                              sp = new Slippers(display,parent);
                             display.setCurrent(sp);
                              break;
                   default:
             else if (c==backCommand) {
                       display.setCurrent(parent);
    }If the 3rd option is selected, i'll display above mentioned layout which contain a list to select too.
    After build this project on WToolkit. It shown an error message which is as below:
    Project settings saved
    Building "SelectCustest"
    C:\WTK22\apps\SelectCustest\src\Catalogues.java:29: cannot resolve symbol
    symbol : method getSelectedIndex ()
    location: class javax.microedition.lcdui.Displayable
    switch(parent.getSelectedIndex()){
    ^
    1 error
    com.sun.kvem.ktools.ExecutionException
    Build failed
    May i know what is problem am i facing now? And how to solve it.
    Thanks.

    Thanks to all for your thoughts and replies. I liked the xargs suggestion, so I tried that first. I would have (may still) try the stdin suggestion, followed by writing the grep output to a file.
    xargs does work, in a way I didn't expect it to, but that could be due to my inexperience with the workings of the shell.
    here's a line from my test script
    cat file | grep foo | xargs java com.company.test.TEchoArghere's the contents of 'file'
    123foo
    abc
    qafoozv
    qaz
    wsx
    qwefoort
    zxcfooh
    sdfghhere's the output from the test class, which just echos any arguments
    ::number of args: 4
    ::args[0] 123foo
    ::args[1] qafoozv
    ::args[2] qwefoort
    ::args[3] zxcfoohso xargs appends all the values from grep into an argument list and call the java class once.
    when I took xargs out of the script, nothing was passed to the class:
    ::number of args: 0this was really interesting and something to keep in my back pocket for future use.
    Thanks again to all.
    Tom

  • Why do most of my stacks come ungrouped when I make changes to other files in the same folder?

    I have a folder of about 3000 graphics and photos that I use for work. I've meticulously organized them all by using unique file names, keywords, and sorting. However, when I make changes to a set of files (especially using the batch rename tool), a large percentage, even a majority, of the other stacks in the folder come ungrouped.
    This has been happening to me for several months, and so far I can't see any type of order or factor that makes certain files come ungrouped. Many times, it's the same files that come ungrouped, but in addition to those, there will be other random stacks that I lose. My stacks are only a few files big (each stack is comprised of the same picture in different file types) and with how many files I have, this has become seriously detrimental to my workflow and efficiency. Anywhere from 20-70 stacks will become ungrouped. I almost always have my files sorted by filename, and when I rename files using batch rename, I give them such similar names that I'd think there would be no reason for the rest of my files to come ungrouped. For example, if there are three files I want to group, I will give them a name like background_001, background_002, and background_003. After I do this, I'll discover that my stacks with names like template_(sequence number) and UI_(sequence number) have come ungrouped. It will do this with pages and pages of stacks at the same time, regardless of how I have the files / stacks sorted. It doesn't happen everytime I rename a batch, either. I just created 10 batches of 3 like-named files each, and after this last batch, about a hundred files came ungrouped.
    I understand that doing things like changing the sorting method of files, or renaming a file so that it's thrown in the middle of a stack, will ungroup my stacks. I don't think I'm doing any of these things (I've been trying desperately to make sure I don't change the sorting method of my files or do anything to a file that might have an effect like this). I don't use ratings or color labels in these folders, the only tools I use are batch rename, keywords, and stacks.
    Is there any way to preserve my stacks so this stops happening in the future, or I can correct it when it does?

    This is my first time posting here, so I'm sorry, I re-read my post several times and honestly did think I provided enough information, but you're right, it wasn't the right kind. So please (continue to) bear with me, I'm really not trying to be ignorant. I honestly assumed the issue was something I was doing wrong in Bridge, nothing to do with my computer specs.
    I am using a late-2008 Macbook, running Yosemite 10.1.1 (screenshot below)
    On the Mac I am using Bridge CC 6.1.1.115 and Photoshop CC 2014 (2014.2.1 release, 20141014.r.257 x64)
    Here is a link to the System Info from Photoshop on the Mac
    Here is a screenshot of my System Overview on the Mac
    Here is a screenshot of my Photoshop performance preferences on the Mac
    I am also using a Dell desktop with Windows 8, running Photoshop CC 2014 (2014.2.1 release, 20141014.r.257 x32) and Bridge CC 6.1.0.116 x32 (on a separate CC account with separate files that I don't try to sync or anything)
    Here is a link to the System Info from Photoshop on the Windows computer.
    Here is a screenshot of the system overview on the Windows
    Here is a screenshot of my Photoshop Performance preferences on the Windows computer
    I work with jpg, psd, ai, svg, and pdf files. Most of my stacks are three different file types of the same image, usually jpg, psd/ai, and pdf.
    I have not recieved any error messages
    I am not having issues opening raw files, I am not having printing issues, I have listed the troubleshooting steps I have taken.
    Is there any information you need that I missed? I'm trying not to be a dingus, but I'll have to ask you to be patient with me in the meantime. I haven't ever looked up half the hardware/software details that were suggested and I don't know how to off the top of my head, so I provided what I already knew how to

  • Problem - different classes in a custom list

    Hi,
    Im making a school project and must use this List-class, written by some of our teachers.
    The problem is, the nodes in the list are type of Objects, and i must store multiple types of classes in the list.
    Storing works fine, but when i want to do something with a specific item in the list, i cannot use it's methods since its now type Object. So everytime I want to use it, i have to cast the Object back to the class it was originally, and there are like 20 of them so thats hell of a lot if-clauses to check which type must i cast it to, and thats in every place that does something with the list.
    Am I being extremely dumb here? Whats the proper way to do this?

    ju551 wrote:
    All the objects are kind of creatures that are inherited from the same abstract class.
    Hmm did i get this right now... So if i make that ancestor class into an interface, I can just cast them everytime to that class and when i call its (abstract) methods it will invoke the real methods in the subclasses?Ah, you don't need an interface in that case. You can just cast all instances to the base class and call the methods that are available there. The methods in the subclasses will be called if they are overridden.
    Kaj

  • Cycle Counting is not fetching All Items in Different Classes

    Hi All,
    My client has performed cycle counting. Ideally system has to fetech all the items in different classes. But in cycle counting listing report only able to fetch few items.
    Please let me know are we missing something ?
    And please let me know the significance of "Assign Items". How to put the same.
    Regards,
    John
    Edited by: 911765 on Mar 14, 2012 4:36 AM

    1) CC won't fetch all items in all classes.
    It will look at only those items that are present in the assign items screen.
    It will only consider those items which have cycle count enabled flag set to Yes in item master
    It will only consider those items that have a non-zero frequency for the ABC class of the item.
    It will only print those items that have some onhand if you run the CC to ignore zero onhand items.
    2) You can either manually add items to a CC in the assign items window.
    OR
    You can reinitialize or update the CC (by going to the 3rd tab on CC screen)
    Make sure that you have run ABC compilation so each item has a ABC class. You should also specify the frequency for each ABC class.
    Sandeep Gandhi

  • When FT is full screen, camera goes off when swiping to a different app

    When FT is full screen, camera goes off when swipping to a different app or the desktop. This is frustrating to the other person. We were having a discussion and I said I wouls look it up and when I swipped to Safari, the camera went off. It makes the other person think the connection has been lost. Anywhere to report issues like this to Apple?

    In reading other threads, I found a few that recommend a hard reset to solve the issue.  I have tried it, and thus far haven't expereienced the problem again.  Hopefully that's it then

  • Invoke a method in one class from a different class

    I am working on a much larger project, but to keep this simple, I wrote out a little test that would convey the over all theory of the program.
    What I am doing is starting out with a 2 JFrames and a Class. When the program is launched, the first JFrame opens. In this JFrame is a label and a button. When the button is clicked, the second JFrame opens. This JFrame has a textField and a button. The user puts the text in the textField and presses the button. When the button is pushed, I want the text that was just put in the textField, to be displayed in the first JFrame's label. I am trying to invoke a method in the first JFrame from the second, but nothing happens. I have also tried making the Class extend from JFrame1 and invoke it from there, but no luck. So, how do I invoke a method in a class from a different class?
    JFrame1 (I omitted the layout part. I made this in Netbeans so its pretty long)
    public class NewJFrame1 extends javax.swing.JFrame {
         private NewClass1 nC = new NewClass1();
         /** Creates new form NewJFrame1 */
         public NewJFrame1() {
              initComponents();
              jLabel1.setText("Chuck");
         public void setLabels()
              jLabel1.setText(nC.getName());
    private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {                                                  
         NewJFrame2 j2 = new NewJFrame2();
         j2.setVisible(true);The class
    public class NewClass1 {
         public static String name;
         public NewClass1()
         public NewClass1(String n)
              name = n;
         public String getName()
              return name;
         public void setName(String n)
              name = n;
    }The second jFrame
    private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {                                                  
         NewClass1 nC = new NewClass1();
         NewJFrame1 nF = new NewJFrame1();     
         nC.setName(jTextField1.getText());
         nF.setLabels();
         System.out.println(nC.getName());At this point I am begging for help. I have been trying for days to figure this out, and I just feel like I am not getting anywhere.
    Thanks

    So, how do I invoke a method in a class from a different class?Demo:
    public class Main {
        public static void main(String [] args) {
         Test1 t1 = new Test1();
         Test2 t2 = new Test2();
         int i = t1.method1();
         String s = t2.method2(i);
         System.out.println(s);
    class Test1 {
        public int method1() {
         return 10;
    class Test2 {
        public String method2(int i) {
         if (i == 10)
             return "ten";
         else
             return "nothing";
    }Output is "ten".
    Edited by: newark on May 28, 2008 10:55 AM

Maybe you are looking for

  • Dell p2815q no longer working with Macbook Pro A1398

    Hi, Some time ago I bought a dell p2815q monitor. It would work just fine using the display port to thunderbolt connector. After some time my Mac Pro simply stopped picking it up. When I connect it, it seems like it tries to display on it but it blin

  • What is the appropriate data expiration / eviction scheme for the following scenario

    We currently have an expiration scheme through which data entries in cache-A get expired after the cache hits a certain size. The LRU entries are expired after the max threshold is reached. But the issue is that certain entries in the cache are rende

  • I can't purchase a photo book from Apple?

    I have for a few years now been making iPhoto books and sending to Apple for printing.  I have a few year books in the cue and recently tried to purchase the books (send to apple) and it's says I cannot do this now, my iPhoto is out of date. So I tri

  • JDBC Adapter: unique constraint

    Hi, my scenario: IDoc -> XI -> JDBC. I would like to know whether the data processing on my Oracle database was successful or not. If an unique constraint fails on oracle (i have test it) the idoc has status successful although (XI: SXMB_MONI) . how

  • Mountain Lion and Lion very slow on Macbook 13' 2010 Middle

    The problem is the Mountain Lion and Lion very very slow, but Snow Leopard was fast. The Lion bit faster, the Mountain Lion is much slower. Animations are choppy and slow, but sometimes fast, but mostly random stuttering. If i have multiple windows o