<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Help with OO program in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356282#M177752</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello James,&lt;/P&gt;&lt;P&gt;You have got it right!!&lt;/P&gt;&lt;P&gt;Both the methods pitch_area and display_area i suppose do the calculation of area based on parameter p_data.&lt;/P&gt;&lt;P&gt;So you need not override (what u termed as redefine) the method display_area.&lt;/P&gt;&lt;P&gt;Also a method pitch_area cannot override display_area.&lt;/P&gt;&lt;P&gt;It need to be so same interface. &lt;/P&gt;&lt;P&gt;For example, &lt;/P&gt;&lt;P&gt;if u declare your display_area method as follows in base class Property :&lt;/P&gt;&lt;P&gt;method display_area . &lt;/P&gt;&lt;P&gt;area = p_data * p_data.&lt;/P&gt;&lt;P&gt;endmethod.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now if u use this method in the child class FootballPitch,&lt;/P&gt;&lt;P&gt;it will do the same work of finding area..&lt;/P&gt;&lt;P&gt;U can overide it here..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;method display_area . &lt;/P&gt;&lt;P&gt;area = 2 * p_data * p_data.&lt;/P&gt;&lt;P&gt;endmethod.&lt;/P&gt;&lt;P&gt;Now when u use this method, it will give u 2 times the area .&lt;/P&gt;&lt;P&gt;However, for class RaceTrack,&lt;/P&gt;&lt;P&gt;the method display_area would still give u the area..&lt;/P&gt;&lt;P&gt;Hope that explains th point..&lt;/P&gt;&lt;P&gt;Shall mail u documents on this topic once i get back to office on tuesday...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Tanveer.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note: Please mark helpful answers on SDN as thats the only way to appreciate someones efforts..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 30 Apr 2006 20:28:26 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-04-30T20:28:26Z</dc:date>
    <item>
      <title>Help with OO program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356278#M177748</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello.  I have a base class called Property.  It gets data from the program in the form of a parameter p_data. There are 2 methods getdata(gets p_data from the program) and display_area(calculate and print the area)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have two subclasses called FootballPitch and RaceTrack which are inheriting from Property.  There are two methods:  Pitch_area(calculate the area using p_data) and display_pitch(this redefines display_area in the super class).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The second subclass will work in a similar way.  I am new to classes in ABAP so I need some assistance.  Thank you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;James&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 30 Apr 2006 12:29:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356278#M177748</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-04-30T12:29:36Z</dc:date>
    </item>
    <item>
      <title>Re: Help with OO program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356279#M177749</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi James,&lt;/P&gt;&lt;P&gt;Welcome to SDN!!&lt;/P&gt;&lt;P&gt;Can u tell us in what way would u need assistance..&lt;/P&gt;&lt;P&gt;If syntax is the problem...&lt;/P&gt;&lt;P&gt;refer&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/2503f09c-0801-0010-dc89-80bab376e4b8" target="test_blank"&gt;https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/2503f09c-0801-0010-dc89-80bab376e4b8&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This shall help u solve your problem and is excellent tutorial for freshers.&lt;/P&gt;&lt;P&gt;Was of great help to me too.&lt;/P&gt;&lt;P&gt;Hope that helps!!&lt;/P&gt;&lt;P&gt;Let me know your email id and i shall mail the documents to you alonf with some good documents&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Tanveer.&lt;/P&gt;&lt;P&gt;Please mark answers by clicking on the star at the top&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 30 Apr 2006 12:59:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356279#M177749</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-04-30T12:59:47Z</dc:date>
    </item>
    <item>
      <title>Re: Help with OO program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356280#M177750</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I would like to know how to use pitch_area to redefine display_area.  What will the method look like?  It seems to me that pitch_area is not needed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;James&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 30 Apr 2006 15:12:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356280#M177750</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-04-30T15:12:01Z</dc:date>
    </item>
    <item>
      <title>Re: Help with OO program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356281#M177751</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi James,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Well, you understood that nicely.See the only important thing to do is to redefine the display_area method.Here u CANNOT CHANGE THE METHOD INTERFACE, whereas you are free to change code according to your need.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;best regards,&lt;/P&gt;&lt;P&gt;Bharat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 30 Apr 2006 17:48:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356281#M177751</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-04-30T17:48:49Z</dc:date>
    </item>
    <item>
      <title>Re: Help with OO program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356282#M177752</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello James,&lt;/P&gt;&lt;P&gt;You have got it right!!&lt;/P&gt;&lt;P&gt;Both the methods pitch_area and display_area i suppose do the calculation of area based on parameter p_data.&lt;/P&gt;&lt;P&gt;So you need not override (what u termed as redefine) the method display_area.&lt;/P&gt;&lt;P&gt;Also a method pitch_area cannot override display_area.&lt;/P&gt;&lt;P&gt;It need to be so same interface. &lt;/P&gt;&lt;P&gt;For example, &lt;/P&gt;&lt;P&gt;if u declare your display_area method as follows in base class Property :&lt;/P&gt;&lt;P&gt;method display_area . &lt;/P&gt;&lt;P&gt;area = p_data * p_data.&lt;/P&gt;&lt;P&gt;endmethod.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now if u use this method in the child class FootballPitch,&lt;/P&gt;&lt;P&gt;it will do the same work of finding area..&lt;/P&gt;&lt;P&gt;U can overide it here..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;method display_area . &lt;/P&gt;&lt;P&gt;area = 2 * p_data * p_data.&lt;/P&gt;&lt;P&gt;endmethod.&lt;/P&gt;&lt;P&gt;Now when u use this method, it will give u 2 times the area .&lt;/P&gt;&lt;P&gt;However, for class RaceTrack,&lt;/P&gt;&lt;P&gt;the method display_area would still give u the area..&lt;/P&gt;&lt;P&gt;Hope that explains th point..&lt;/P&gt;&lt;P&gt;Shall mail u documents on this topic once i get back to office on tuesday...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Tanveer.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note: Please mark helpful answers on SDN as thats the only way to appreciate someones efforts..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 30 Apr 2006 20:28:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356282#M177752</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-04-30T20:28:26Z</dc:date>
    </item>
    <item>
      <title>Re: Help with OO program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356283#M177753</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I used redefined the original method in the subclasses.  Pitch_area was not necessary as I thought.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you all for the help.  However, I don't see the radio buttons to award the points to you for helping me.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;James&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 May 2006 23:46:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-oo-program/m-p/1356283#M177753</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-05-01T23:46:53Z</dc:date>
    </item>
  </channel>
</rss>

