<?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: Procedural-2-OOPS in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6061002#M1353993</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Advice from Martin Fowler's Refactoring book:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://sourcemaking.com/refactoring/convert-procedural-design-to-objects" target="test_blank"&gt;http://sourcemaking.com/refactoring/convert-procedural-design-to-objects&lt;/A&gt;&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;Jacques Nomssi Nzali&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 28 Sep 2009 22:25:45 GMT</pubDate>
    <dc:creator>nomssi</dc:creator>
    <dc:date>2009-09-28T22:25:45Z</dc:date>
    <item>
      <title>Procedural-2-OOPS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6060996#M1353987</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;Hello experts,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;I want to rebuild a procedural report to object oriented, can some one tell me which steps i have to do , to redesign it ?&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My Report Structure is :&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;*Structured Types*    


TYPES:BEGIN OF ty_projnum,
             prj_num    TYPE zprojectmst-prj_num,
             prj_name   TYPE zprojectmst-prj_name,
             cat_num    TYPE zprojectcard-cat_num,
       END OF ty_projnum.*
 

TYPES:BEGIN OF    ......
 



  END OF
 

DATA: ........
 


**---------------------------------------------------------------------**
**       Select Options                          **
**---------------------------------------------------------------------**

*..*

**----------------------------------------------------------------------**
 
**     AT SELECTION-SCREEN*
 
**----------------------------------------------------------------------**
 
*...*
 
**---------------------------------------------------------------------**
 
**             S T A R T   O F   S E L E C T I O N                     **
 
**---------------------------------------------------------------------**
 
*...*
 
*with reforms*
 
*..*&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Matt on Sep 7, 2009 9:50 AM - fixed formatting - why was it all BOLD?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Aug 2009 16:20:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6060996#M1353987</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-24T16:20:47Z</dc:date>
    </item>
    <item>
      <title>Re: Procedural-2-OOPS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6060997#M1353988</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;we can't answer as OOPS means an in-depth knowledge of the job done by the program, what you want to reuse, what already exists "outside". You must do it by yourself. Or ask a more precise question.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Aug 2009 19:44:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6060997#M1353988</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2009-08-24T19:44:14Z</dc:date>
    </item>
    <item>
      <title>Re: Procedural-2-OOPS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6060998#M1353989</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So I am new in ABAP Object World, what i knew from Java World have tried on this case but i dont know if it write .&lt;/P&gt;&lt;P&gt;I maked a Class diagram with some classe what i created for the report. &lt;/P&gt;&lt;P&gt;the qustion here is :&lt;/P&gt;&lt;P&gt;is there some thing calls Report Class ? or a class which can do the same work like a report ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Aug 2009 21:16:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6060998#M1353989</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-24T21:16:20Z</dc:date>
    </item>
    <item>
      <title>Re: Procedural-2-OOPS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6060999#M1353990</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In term of OOP, this question makes no sense. Frankly, I recommend you to train on OOP without looking at this program, learn the major notions and make tests with little programs. At the end, you'll better understand if it's worth rewriting your program (there may be no advantage to rewrite it). Have a look at [SDN ABAP Objects section|/docs/DOC-8024#section2 &lt;B&gt;[original link is broken]&lt;/B&gt;]&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 25 Aug 2009 06:49:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6060999#M1353990</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2009-08-25T06:49:33Z</dc:date>
    </item>
    <item>
      <title>Re: Procedural-2-OOPS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6061000#M1353991</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;a possible general structure for your program could be:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;report ydemo.

data: g_model type ref to ycl_report_model,

         g_viewer type ref to ycl_report_viewer.

initialization.

  create object g_model.

at selection-screen.

  g_model-&amp;gt;set_selections( ... ).

start-of-selection.

  g_model-&amp;gt;make_data_selections( ).

end-of-selection.

  create object g_viewer.
  g_viewer-&amp;gt;display( g_model ).&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;YCL_REPORT_MODEL and YCL_REPORT_VIEWER are global classes. The first to select the data, make calculations and so on, the second to display the results.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this helps you,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;Dirk&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Sep 2009 13:16:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6061000#M1353991</guid>
      <dc:creator>dirk_wittenberg</dc:creator>
      <dc:date>2009-09-04T13:16:24Z</dc:date>
    </item>
    <item>
      <title>Re: Procedural-2-OOPS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6061001#M1353992</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The selection screen (SELECT-OPTIONS, PARAMETERS) however, have to be in a procedural report.  So, build on Dirk's code.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;report ydemo.
 
data: g_model type ref to ycl_report_model,
 
         g_viewer type ref to ycl_report_viewer.
 
PARAMETERS: p_param TYPE ...

SELECT-OPTIONS: o_sel FOR ...

initialization.
 
  create object g_model.
 
at selection-screen.
 
  g_model-&amp;gt;set_selections( i_param = p_param ir_sel = o_sel[] ).
 
start-of-selection.
 
  g_model-&amp;gt;make_data_selections( ).
 
end-of-selection.
 
  create object g_viewer.
  g_viewer-&amp;gt;display( g_model ).
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Within set_selections, I define &lt;STRONG&gt;ir_sel&lt;/STRONG&gt; as a STANDARD TABLE.  I then use:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;FIELD-SYMBOLS: &amp;lt;lr_sel&amp;gt; TYPE STANDARD TABLE.
CREATE DATA me-&amp;gt;rr_sel LIKE ir_sel. " rr_sel is an instance attribute of type REF TO DATA
ASSIGN me-&amp;gt;rr_sel-&amp;gt;* TO &amp;lt;lr_sel&amp;gt;.
&amp;lt;lr_sel&amp;gt; = ir_sel.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;In make_data_selections, I do this &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;FIELD-SYMBOLS: &amp;lt;lr_sel&amp;gt; TYPE STANDARD TABLE.
ASSIGN me-&amp;gt;rr_sel-&amp;gt;* TO &amp;lt;lr_sel&amp;gt;.

SELECT * FROM table WHERE sel IN &amp;lt;lr_sel&amp;gt;.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;matt&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Sep 2009 07:58:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6061001#M1353992</guid>
      <dc:creator>matt</dc:creator>
      <dc:date>2009-09-07T07:58:20Z</dc:date>
    </item>
    <item>
      <title>Re: Procedural-2-OOPS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6061002#M1353993</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Advice from Martin Fowler's Refactoring book:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://sourcemaking.com/refactoring/convert-procedural-design-to-objects" target="test_blank"&gt;http://sourcemaking.com/refactoring/convert-procedural-design-to-objects&lt;/A&gt;&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;Jacques Nomssi Nzali&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Sep 2009 22:25:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6061002#M1353993</guid>
      <dc:creator>nomssi</dc:creator>
      <dc:date>2009-09-28T22:25:45Z</dc:date>
    </item>
    <item>
      <title>Re: Procedural-2-OOPS</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6061003#M1353994</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Normally, I'm against single links - but this is a good one.  Very relevant.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Sep 2009 05:20:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/procedural-2-oops/m-p/6061003#M1353994</guid>
      <dc:creator>matt</dc:creator>
      <dc:date>2009-09-29T05:20:54Z</dc:date>
    </item>
  </channel>
</rss>

