<?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 Creating object type conflict dump in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/creating-object-type-conflict-dump/m-p/3498761#M841563</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have an interface &lt;STRONG&gt;zintf_1&lt;/STRONG&gt;. I getting the list of classes that implemented the &lt;STRONG&gt;zintf_1&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;There are some cases where the class wont have implemented the interface.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ZDEMO_AA class has not implemented the interface zintf_1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: lr_intf_1 type ref to zintf_1,&lt;/P&gt;&lt;P&gt;        lv_clsname type SEOCLSNAME.&lt;/P&gt;&lt;P&gt;lv_clsname = 'ZDEMO_AAA'.&lt;/P&gt;&lt;P&gt;try.&lt;/P&gt;&lt;P&gt;create object lr_intf_1 type (lv_clsname).&lt;/P&gt;&lt;P&gt;catch cx_sy_create_object_error.&lt;/P&gt;&lt;P&gt;.....&lt;/P&gt;&lt;P&gt;endtry.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In that case i m getting the dump "Type conflict with allocation of References".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please help me to resolve the issue.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;P&gt;Vimalraj&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 05 Mar 2008 11:19:54 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-03-05T11:19:54Z</dc:date>
    <item>
      <title>Creating object type conflict dump</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/creating-object-type-conflict-dump/m-p/3498761#M841563</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have an interface &lt;STRONG&gt;zintf_1&lt;/STRONG&gt;. I getting the list of classes that implemented the &lt;STRONG&gt;zintf_1&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;There are some cases where the class wont have implemented the interface.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ZDEMO_AA class has not implemented the interface zintf_1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: lr_intf_1 type ref to zintf_1,&lt;/P&gt;&lt;P&gt;        lv_clsname type SEOCLSNAME.&lt;/P&gt;&lt;P&gt;lv_clsname = 'ZDEMO_AAA'.&lt;/P&gt;&lt;P&gt;try.&lt;/P&gt;&lt;P&gt;create object lr_intf_1 type (lv_clsname).&lt;/P&gt;&lt;P&gt;catch cx_sy_create_object_error.&lt;/P&gt;&lt;P&gt;.....&lt;/P&gt;&lt;P&gt;endtry.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In that case i m getting the dump "Type conflict with allocation of References".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please help me to resolve the issue.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;P&gt;Vimalraj&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Mar 2008 11:19:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/creating-object-type-conflict-dump/m-p/3498761#M841563</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-05T11:19:54Z</dc:date>
    </item>
    <item>
      <title>Re: Creating object type conflict dump</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/creating-object-type-conflict-dump/m-p/3498762#M841564</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm assuming that you're trying to trap the case the class lv_clsname doesn't actually implement the interface.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Well, the interface not being there is NOT a catchable error.  So you have to find out whether the interface is implemented first.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA: lr_intf_1  TYPE REF TO zintf_1,
      lv_clsname TYPE seoclsname,
      lr_object  TYPE REF TO cl_oo_class,
      lt_intf    TYPE seo_relkeys.

lv_clsname = 'ZDEMO_AAA'.

lr_object ?= cl_oo_object=&amp;gt;get_instance( lv_clsname ).
lt_intf = lr_object-&amp;gt;get_implemented_interfaces( ).

READ TABLE lt_intf TRANSPORTING NO FIELDS WITH KEY refclsname = 'ZINTF_1'.
IF sy-subrc IS INITIAL.
  CREATE OBJECT lr_intf_1
    TYPE
      (lv_clsname).
  WRITE: 'it worked'.
ELSE.
  WRITE / 'it failed'.
ENDIF.&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>Wed, 05 Mar 2008 15:54:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/creating-object-type-conflict-dump/m-p/3498762#M841564</guid>
      <dc:creator>matt</dc:creator>
      <dc:date>2008-03-05T15:54:12Z</dc:date>
    </item>
  </channel>
</rss>

