Me, Classes and Class rooms

Hi,
note : plz take your lunch on time :)
I have a class called as Datastructure(one of my favorite classes), this class has methods:
addKey(blah,blah...)
containsKey(blah...)
getKey(.....)
getValue(.....)
now I have to design a class clled Parameter, this class has to read patameters (from an ASCII file which does not change)into Datastructure so I extended the Datastructure class as
.blah blah...Parameter extends DataStructure ....{
Parameter's method readParameterFile reads the parameters and internally calles addKey method to fill in values. I am using few of the methods of DataStructure (containdKey, getKey,getValue.....).
Some of DataStructure's methods are not required(or not used )here in Parameter. How should I not include them, or what ever I have done is correct.
(one more thing) I want to call the Parameter's methods as Parameter.getKey()...(with out usingan object of Parameter)
I am STILL new to Object Oreanted programming plz suggest me some good online matrial to learn how-to about designing Classes and learn about object oreanted designing

note : plz take your lunch on time :)It will be another 23 hours in the current timezone.
I am STILL new to Object Oreanted programming plz
suggest me some good online matrial to learn how-to
about designing Classes and learn about object
oreanted designing
http://java.sun.com/docs/books/tutorial/java/index.html

Similar Messages

  • What is the field and Table for "Batch Class" and "Class Type" in QM.

    Hi All,
    What is the field and Table for "Batch Class" and "Class Type" in QM.
    Thanks,

    Hi,
      For batch class the class type value is '023' . This you can find from KLAH table and the fileld for class type is KLART..
    And also all the data related to batch class are found in tables INOB, KLAH,KKSK and for the characeteristics of batch materials you can refer AUSP table.
    In INOB table, for batch class, you need to give 023 in KLART field and  value MCH1 in OBTAB filed.
    Please check this and let me know if this you need any more details?

  • Want to know more about class and class type and characters in batch determ

    hi ,
    i want to know abt class functionality and how it is related to batch mgt,means functions of class type , characters etc.
    ok thanks

    Hi ,
    Find the Class and Class Type for Batch Determination.
    Create Class for Batch Management
    Use
    In this step, you define two classes for use with batches. One class contains the characteristic LOBM_VFDAT: Expiration Date, and the other class with three characteristics:
    LOBM_RL: Remaining shelf life for batch,
    LOBM_LFDAT Batch determination delivery date, and
    LOBM_VFDAT Expiration date, shelf life.
    Procedure1.
    Access the activity using one of the following navigation options:
    Transaction Code: CL02SAP R/3 Role Menu     Installation ® Create Class for Batch Management
    2.Choose Create and maintain the necessary master data manually. The relevant data can be found in the file:
      Class     Class type     Description     Characteristic        Characteristic     Characteristic
    023_001     023     Products with Expiration Date     LOBM_VFDAT     
    023_002     023     Search class with expiration date     LOBM_RLZ     LOBM_LFDAT     LOBM_VFDAT
    Result
    The materials are later assigned to class 023_001 in the material masters. 023_002 is used in the batch determination search strategies for SD and PP/PI. 
    Regards,
    SAROSH

  • Abstract class and class

    What is the difference between abstract class and class in java?

    arcadesstuff wrote:
    Abstract class: a class that contains at least one abstract method. As has already been mentioned, abstract classes need not contain any methods at all. Have a look at the abstract class you posted; it's still abstract, though it contains no abstract methods. Note that if one declares any method of a class abstract, the class itself must be declared abstract as well.
    When you implement the abstract class Animal, you will have to write the code of those two abstract methods from above.Your example contains no abstract methods. Abstract methods must be marked with the keyword "abstract".
    ~

  • Class and class type based on inspection method

    Hi experts,
              I have a requirement in my script like this i have a inspection method. based on this inspection method i have to get class and class type. and from which table we can get this class and class type based on inspection method. please suggest the solution.
    Thanks in advance
    Thanks and Regards
    D.Ramesh

    Hi Sai,
    Have you tried Run Time Type services?  If you need to perform some interspection of a class, you can use one of two classes:
      CL_ABAP_OBJECTDESCR  or
      CL_ABAP_REFDESCR
    there are several methods you can use:
      Describe_by_Name
      Describe_by_Object_Ref
      describe_by_data_ref
      describe_by_data
    One of these should do the trick...it just depends on what situation you are in.
    Hope this helps!
    Quack

  • How can I find characteristic via class and class type

    hi all ,
    i have knew a class and class type , how should i find corresponding characteristic , i mean which table should i access .
    just like cl04 , if you enter class and class type , you should get some characteristics. these characteristics are what i want .
    please guide me .
    best regards
    Kevin

    Use
    INOB Table
    INOB-OBJEK = Material No.
    OBTAB = MARA
    Get CUOBJ and KLART(class type)
    KSSK   Table
    OBJEK = INOB-CUOBJ
    MAFID = 'O'
    KLART = INOB-KLART
    GET CLIENT
    from KLAH with KSSK-CLIENT
    Get class no.
    Call the function module CLAF_CLASSIFICATION_OF_OBJECTS with the following input parameters
    Class            =  
    Class Type     =  
    Object
    Object table
    U get Object Data table , it have ur Characteristic value from AUSP table.

  • Help required: Classes and class values for Func Loc

    Dear All,
    I have a requirement to get the classes and values associated with a functional location.
    Any idea how to get this data, as in IL03.
    Thanks,
    nsp.

    Hello nsp,
    You can try to check out the Function module ALM_ME_TOB_CLASSES to see how they fetched class, characteristics and their values.
    You can keep a break-point in this module and run MAM30_031_GETDETAIL and check how we can pass the appropriate values.
    However, above FMs are available from PI 2004.1 SP 14 of release 4.6c, 4.7 and 5.0.
    If you are in ERP 6.0, the FM's are available.
    Hope this helps
    Best Regards,
    Subhakanth

  • MIF: Split class and Class -- always alpha order

    When I use the MIF doclet with an XML book file that specifies classes to include in the book, and I use the <Split>class</Split> option, the doclet always puts the classes in alphabetical order, not in the "logical" order that I specify. I get the desired subset of the package, just not in the desired order.
    You can reproduce this with the sample XML files in the test/example-bookfile directory, if you comment out the <InsertAPIDoc> line, comment in the <Chapter>s that contains <Package>s and <Class>es, and fix the class names to match the actual sample source (e.g., SubClass, not SubClass1).
    The workarounds are:
    1. Use <Split>package</Split> instead of <Split>class</Split>.
    2. Use a separate FrameMaker book file, not the auto-generated one; this makes an automated process more difficult.
    I didn't find this in the bug database, though there is 4645280 about packages being "silently sorted".

    This is a known bug. I am surprised that it has not been filed. I will search for it again and file a new bug if I don't find it. A new version of the doclet that supports new J2SE 1.5 language features will soon be released. You can expect this bug to be fixed in that release.
    -Jamie

  • Question about Abstract Classes and Class Inheritance

    The semester is winding down, and the assignments are getting more complicated....
    Prof has given us a project involving both an interface and an abstract class. There's a class Person, then an abstract class Employee that extends Person, and two types of Employees (Hourly and Salaried) that extend Employee. The finished assignment is a type of payroll program that's supposed to be able to store both types of Employees and related info (name, salary, etc). One thing the prof suggested was to store both HourlyEmployees and SalariedEmployees in an array of Employees. But you can't instantiate an array of Employees directly, of course, since it's an abstract class.
    So is it possible to create an array of Persons, cast either HourlyEmployees or SalariedEmployees into Employee objects, and then store the Employee objects in the Person array? And if I do that, can I still use methods particular to the SalariedEmployees and/or HourlyEmployees once they are in the Person array? Or can I store SalariedEmployee and HourlyEmployee directly in an array of Persons, without having to cast them into anything else? (In that case, I'm not sure what the point of having the abstract Employee class is, though). Do they become just generic "Persons" if I do this?
    Thanks for any help!

    But you
    can't instantiate an array of Employees directly, of
    course, since it's an abstract class.Sure you can. You just can't instantiate Employee (the abstact class itself, as opposed to its subclasses) objects.
    Employee[] employees = new Employee[20];
    employees[0] = new HourlyEmployee();That should work.
    So is it possible to create an array of Persons, cast
    either HourlyEmployees or SalariedEmployees into
    Employee objects, and then store the Employee objects
    in the Person array?You could do that as well, but you shouldn't need to cast it.
    Given the type hierarchy you describe, an HourlyEmployee is a Person, so you should be able to assign an HourlyEmployee directly to a Person-valued variable.
    And if I do that, can I still use
    methods particular to the SalariedEmployees and/or
    HourlyEmployees once they are in the Person array?No. If the method doesn't exist in Person, then you can't call it on a Person variable, even if the method does exist in the class implementing Person.
    But if the method exists in Person, but is implemented and possibly overridden in HourlyEmployee, you can still invoke it, by just invoking the Person method.
    public interface Person {
      public void feed();
    public abstract class Employee implements Person {
      public abstract void hire();
    public class HourlyEmployee extends Employee {
    // then:
    Person persons = new Person[20];
    // add HourlyEmployees or SalariedEmployees to persons array...
    persons[0].feed(); // OK!
    persons[0].hire(); // NOT OK!

  • Can I use classes and methods for a maintenance view events?

    Hello experts,
    Instead of perform/form, can I instead use classes and methods, etc for a given maintenance view event, lets say for example I want to use event '01' which is before saving records in the database. Help would be greatly appreciated. Thanks a lot guys!

    Hi viraylab,
    1. The architecture provided by maintenance view
       for using EVENTS and our own code inside it -
       It is provided using FORM/PERFORM
       concept only.
    2. At this stage,we cannot use classes.
    3. However, inside the FORM routine,
       we can write what ever we want.
       We can aswell use any abap code, including
       classes and methods.
      (But this classes and methods won't have any
       effect on the EVENT provided by maintenance view)
    regards,
    amit m.

  • What is the diff b/w Abstract class and an interface ?

    Hey
    I am always confused as with this issue : diff b/w Abstract class and an interface ?
    Which is more powerful in what situation.
    Regards
    Vinay

    Hi, Don't worry I am teach you
    Abstract class and Interface
    An abstract class can have instance methods that implement a default behavior. An Interface can only declare constants and instance methods, but cannot implement default behavior and all methods are implicitly abstract. An interface has all public members and no implementation. An abstract class is a class which may have the usual flavors of class members (private, protected, etc.), but has some abstract methods.
    Edited by SASIKUMARA
    SIT INNOVATIONS- Chennai
    Message was edited by:
    sasikumara
    Message was edited by:
    sasikumara

  • Problem with reference and class

    I would like to transit a Data object in member function of another class with Labview 9.0 reference with "In place element structure". I use the reference for optimize allocation memory.
    When i use a dispatch static : Vi is executable  -> "TestRefAppExt Statique.vi"
    With Dispatch dynamic : Vi is not executable (because Read/Write a reference's data value : class's Object in a reference can't be replaced by another) -> "TestRefAppExt DynamiqueWithoutParent.vi"/"TestRefAppExt DynamiqueWityParent.vi"
    When i use Preserve Run-Time Class function the Vi becomes executable
    but it creates some allocations. Labview creates copy of data object
    when i'm running the vi. (increase size of data you'll see)
    The problem is that i can't recuparate the same object without copy in dispatch dynamic. Because LabView can't change the data object transited in a dispatch dynamic function of another class (child class).
    I compared in project labview Execution's performance with and without Reference in dynamic and static and for compare, with Message Box and a Reference of Data object's cluster.
    Without reference, i made three Vi : "TestAppExt Statique.vi", "TestAppExt DynamiqueWithParent.vi" and  "TestAppExt DynamiqueWithoutParent.vi"
    The static's function works well, but when Labview calls dispacth Dynamic functions, it works more slowly.
    With reference, i made three vi too : "TestRefAppExt Statique.vi", "TestRefAppExt DynamiqueWithParent.vi" and "TestRefAppExt DynamiqueWithoutParent.vi" with cast Preserve Run-Time Class.
    All This functions are more slowly than without reference.
    I tried for fun to test with the same class with Message Box : "TestRefAppExt Fifo.vi" and Cluster "TestRefAppExt DynamiqueCluster.vi" with the dynamic function. The result is better than with reference in dynamic.
    "TestRefAppExt StatiqueRef.vi" and "TestRefAppExt DynamiqueRef.vi" are a solution of this problem but it's better to work with In place element structure. And it doesn't resolve reference performance in execution.
    Why it's not possible to recuperate data object after a dispatch dynamic?
    Why the performance is not good with LabView reference 2009?
     I attached the project.
     Could you help me please
    thank you so much.
    Pascal
    Attachments:
    RefTest.zip ‏476 KB

    Yes, it helps but there is one thing that isn't being replicated which is the possibility to remove the link from the generated editor.
    My EMF looks like:
    @gmf.node(label="uri", figure="ellipse", label.edit.pattern="{0}", label.view.pattern="<<Class>> {0}", label.icon="false")
    class Class extends Resource {
    @gmf.link(target="subClassOf", target.decoration="arrow", label.text="subClassOf", label.readOnly="true")
    ref Class[*] subClassOf;
    And when I do the fix with self.subClassOf.remove(self) the link isn't removed (although now the model now passes the validation). Is there any easy way to do that?
    Regards

  • How to find classtype and class for a material.

    Hi,
    How to find classtype and class for a material.
    which table contains this data.
    Thanks
    Kiran

    Hi Kiran,
    Check below sample code. Use this BAPI which will give all info about the class for the material.
      DATA:      l_objectkey_imp    TYPE bapi1003_key-object
                                         VALUE IS INITIAL.
      CONSTANTS: lc_objecttable_imp TYPE bapi1003_key-objecttable
                                         VALUE 'MARA',
                 lc_classtype_imp   TYPE bapi1003_key-classtype
                                         VALUE '001',
                 lc_freight_class   TYPE bapi1003_alloc_list-classnum
                                         VALUE 'FREIGHT_CLASS',
                 lc_e               TYPE bapiret2-type VALUE 'E',
                 lc_p(1)            TYPE c             VALUE 'P',
                 lc_m(1)            TYPE c             VALUE 'M'.
      SORT i_deliverydata BY vbeln posnr matnr.
      CLEAR wa_deliverydata.
      LOOP AT i_deliverydata INTO wa_deliverydata.
        REFRESH: i_alloclist[],
                 i_return[].
        CLEAR:   l_objectkey_imp.
        l_objectkey_imp = wa_deliverydata-matnr.
    *Get classes and characteristics
        CALL FUNCTION 'BAPI_OBJCL_GETCLASSES'
          EXPORTING
            objectkey_imp         = l_objectkey_imp
            objecttable_imp       = lc_objecttable_imp
            classtype_imp         = lc_classtype_imp
    *   READ_VALUATIONS       =
            keydate               = sy-datum
            language              = sy-langu
          TABLES
            alloclist             = i_alloclist
    *   ALLOCVALUESCHAR       =
    *   ALLOCVALUESCURR       =
    *   ALLOCVALUESNUM        =
            return                = i_return
    Thanks,
    Vinod.

  • Using java class and variables declared in java file in jsp

    hi everyone
    i m trying to seperate business logic form web layer. i don't know i am doing in a right way or not.
    i wanted to access my own java class and its variables in jsp.
    for this i created java file like this
    package ris;
    import java.sql.*;
    import java.sql.Connection;
    import java.sql.DriverManager;
    import java.sql.SQLException;
    public class  NewClass{
        public static void main(String args[]){
            Connection con = null;
            ResultSet rs=null;
            Statement smt=null;
            try{
                Class.forName("com.mysql.jdbc.Driver").newInstance();
                con=DriverManager.getConnection("jdbc:mysql:///net","root", "anthony111");
                smt=con.createStatement();
               rs= smt.executeQuery("SELECT * FROM emp");
               while(rs.next()){
                String  str = rs.getString("Name");
                }catch( Exception e){
                    String msg="Exception:"+e.getMessage();
                }finally {
          try {
            if(con != null)
              con.close();
          } catch(SQLException e) {}
    }next i created a jsp where i want to access String str defined in java class above.
    <%--
        Document   : fisrt
        Created on : Jul 25, 2009, 3:00:38 PM
        Author     : REiSHI
    --%>
    <%@page import="ris.NewClass"%>
    <%@page contentType="text/html" pageEncoding="UTF-8"%>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
       "http://www.w3.org/TR/html4/loose.dtd">
    <html>
        <head>
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
            <title>JSP Page</title>
        </head>
        <body>
            <h1><%=str%></h1>
        </body>
    </html>I wanted to print the name field extracted from database by ResultSet.
    but it gives error cannot find symbol str.
    please help me to find right way to do this.
    i am using netbeans ide.

    Very bad approach
    1) Think if your table contains more than one NAMEs then you will get only the last one with your code.
    2) Your String is declared as local variable in the method.
    3) You have not created any object of NewClass nor called the method in JSP page. Then who will call the method to run sql?
    4) Your NewClass contains main method which will not work in web application, it's not standalone desktop application so remove main.
    Better create an ArrayList and then call the method of NewClass and then store the data into ArrayList and return the ArrayList.
    It should look like
    {code:java}
    package ris;
    import java.sql.*;
    import java.sql.Connection;
    import java.sql.DriverManager;
    import java.sql.SQLException;
    public class  NewClass{
        public static ArrayList getNames(){
            Connection con = null;
            ResultSet rs=null;
            Statement smt=null;
            ArrayList nameList = new ArrayList();
            try{
                Class.forName("com.mysql.jdbc.Driver").newInstance();
                con=DriverManager.getConnection("jdbc:mysql:///net","root", "anthony111");
                smt=con.createStatement();
               rs= smt.executeQuery("SELECT * FROM emp");
               while(rs.next()){
                nameList.add(rs.getString("Name"));
               return nameList;
                }catch( Exception e){
                    String msg="Exception:"+e.getMessage();
                   </code><code class="jive-code jive-java"><font>return nameList;</code><code class="jive-code jive-java">
                }finally {
          try {
            if(con != null)
              con.close();
          } catch(SQLException e) {}
          </code><code>return nameList;</code>
    <code class="jive-code jive-java">    }

  • Customizing FD01 and FB70 using PS Class and Characteristics

    Hello SAP Experts
    I have the following issue:
    My client has a requirement where we need to customize the Customer Master  (FD01) screen and the Invoice Posting Screen (FB70). A few additional fields have to be added by creating a separate tab. I was intending to take Abaper's help and do this using user exits but I have been suggested by the cleint to use SAP PS Class and Characteristics feature to do this. Can someone please throw some light on this feature and how can i create custom fields on FD01 and FB70 screens. Is there a way we could customize these screens using PS class and characteristics. Your opinions would be much appreciated.
    Please kindly give your suggestions. Thanks in advance
    Regards,
    Nik

    Joao Paulo,
    Thank you for the response. I have tried to obtain some info from OSS but no luck. Tried all means but there is limited information available.
    Nik

Maybe you are looking for

  • Sizing issues with macbook

    Hi, I've got a Macbook with os 10.4.11 and two problems re: sizing. 1st-I can't get it to print the full size on my canon mp830 printer. It reduces to about a third of the size and moves to the top left corner. I've tried everything I can think of to

  • Transparently implementing an autoincrement trigger?

    I'm developing an application using object-relational mapping framework (Toplink Essentials). The schema design is restricted by certain policy rules, one of which is that every table should have a single primary key column. This also applies to join

  • Where's the original?

    I just removed some spots from a photo in the Development module using the "Spot Removal" tool. It worked great, but I'd like to see the original, because I'm told LR2 is non destructive. I went back to the Libary module, but I don't see the original

  • Crazy input lag in digital painting software

    Hi,    at work I have a MacBook Air 13" Mid-2012 (CPU i5 1.8 GHz, SSD 128 GB, RAM 8 GB, OS X 10.8.5) connected to an external monitor (DELL ultrasharp). I tried to use this computer with some digital painting software (like Adobe Photoshop, Corel Pai

  • My recordings sound so different when exported to iTunes. What am I doing wrong?

    Google's been useless in finding answers. I made a couple songs. They sound perfect on Garageband. After exporting, the songs sound awfully mixed on iTunes. I mean, awful. I've tried messing with iTunes EQ, Garageband visual EQ, Garageband compressio