No instances can be created from abstract classes

Dear SAPGurus,
I have developed a oData Service in my backend system & able to register the service in the gateway hub system. When i try to execute the metadata of the service from gateway system i am able to see the metadata with list of entity types availble in the data model.
But when i try to execute with entity set i am getting the following error.
"The class 'ZCL_ZGRC_DATA_MODEL_DPC' is abstract. No instances can be created from abstract classes."
Where my data model provider class name is  'ZCL_ZGRC_DATA_MODEL_DPC'
Kindly help me.
Thanks & Regards,
Rumeshbabu S

Hello Rumesh,
I do not think the error which u are getting is because of System Alias setting in SPRO.
Its something else which is really strange.
However the below is the setting to be maintained in GW SPRO system alias when u have a environment setup like u have now.
I mean the way u have created service and registered -
In ECC system u have created service using builder.
In GW system u have registered it and trying to access now via an RFC destination.
We have the same setup like u have now and we do not have any issues. We have also maintained the System Alias like i have shared in screen shot.
Check your System Alias config once in SPRO. But i dont think this is causing problem in your case. Still check once.
As per my understanding, from GW its trying to hit the DPC class and hence i feel system alias setting is correct in your case.
Problem is something else which is really strange.
Check error logs and see if it can. Share the error log please.
Regards,
Ashwin

Similar Messages

  • Geting subclass info from abstract class

    Does ne one know how i can retreive informtion from the subclasses of an abstract class by creatinig an instance of the abstract class.
    are Methods such as getClass used?

    Does ne one know how i can retreive informtion from
    the subclasses of an abstract class by creatinig an
    instance of the abstract class.You can never create an instance of the abstract class. That is why they are called abstract.
    >
    are Methods such as getClass used?
    Coming to your actual question, a superclass will not know anything about its children. So you will have to do something else get that information.
    Maybe inspecting all the classes in a classloader and checking its parent will be an option. I do not think this is possible, because ClassLoader does not provide a mechanism to get all the classes.
    Somebody else might give you a better answer. I am just trying to answer one part of your question concerning abstract classes.

  • Is it possible with the goop toolkit to create an abstract class?

    Here is an example of why I want to do this.
    You could write a main VI which calls subVIs of this abstract class but passes references of derived classes to the subVIs.

    Sure. The way that I do this is to create a class that is composed of one or more other class instances. For example, if A has a B, then "A Create.vi" should call "B Create.vi". The reference to the new instance of B should be stored in A's data (Add B's refnum control to A's data cluster type-def). Whenever you need to access B's functionalities, get the reference from A's data cluster and then call B's VIs. Make sure the "A Destroy.vi" calls "B Destroy.vi" passing the reference to the instance of B, stored by A.
    Good luck.
    -Jim

  • How can I casting from parent class to children class

    Dear,
    Could someone help me to casting from parent class to children class.
    I have class like this
    class parent{
    String name;
    String id;
    public String getId() {
    return id;
    public void setId(String id) {
    this.id = id;
    public String getName() {
    return name;
    public void setName(String name) {
    this.name = name;
    class children extends parent{
    String address;
    public String getAddress() {
    return address;
    public void setAddress(String address) {
    this.address = address;
    public children() {
    public children(parent p) {
    //Do init super class here
    In the constructor
    public children(parent p) {
    //Do init super class here
    I like to init super class by object p (this is instance of parent class). The way to do is using:
    public children(parent p) {
    super.setId(p.getId());
    super.setName(p.getName());
    But I don't like this, because, for example I have parent class with over 30 proberties, it take time to do like that.
    There are any way to use super operation to init parent class, for example super = p;
    Could you show me the way.
    Thanks alot

    If I understand your question correctly, you are in need of a copy constructor for you class Parent. A copy constructor behaves like this:
       Parent one = new Parent();
       one.setName("...");
       //... and all other properties of interest
       Parent two = new Parent(one);
       //Now two != one, but one.getName().equals(two.getName) for property name and all othersThe copy constructor is programmed in the Parent class, more later. Then for your child class you can use it as follows
       public class Children extends Parent {
           public Children(Parent p) {
              super(p);
       }There are at least 3 ways of programming a copy constructor:
    1. Just bite the bullet: type the assignment for each field this.name = p.getName()
    2. Use reflection to find all common setters/getters dynamically and assign using them
    3. Use a code generator that uses 2 to give you the code for solution 1 for you to paste in.
    If you find doing this a lot, there are frameworks that can do these mappings, like Dozer
    (PS be carefull with Date fields, don't copy the reference but create a new and equals instance, the dirty way would be this.birthdate = new Date(p.getBirthdate.getTime()); )

  • How to read data from abstract class

    Hi,
    I have an abstract class which has a try block in the run method which looks like this:
    public void run()
    throws exception
    try
    ArrayList xCoord = new ArrayList();
    Double xValue = null;
    for (j=0; j<10; j++)
    xValue = new Double (table.getX(j).toDouble());
    xCoord.add(xValue); // to populate arraylist
    i also have the required catch statements, i have not written them here to keep in concise.
    My question is: How do I read the values stored in the xCoord arraylist from another 'concrete' class derived from the above abstract class.
    I know that for this, I first have to be able to execute the above "run" method, because that is how the arraylist will get populated with values. But how do I do this from the concrete class?
    Then, once the arraylist is formed, how do I read the values from the concrete class, without copying all the code?
    Any guidance will be really helpful. Thanks -- Vinay.

    Add a public or protected accessor (getter) method to retrieve the value calculated in run(). Modify run() to store the results in an instance variable in the abstract class.
    - Saish

  • Can not create a CDC class lib which's refer to another lib.

    Hello, Everybody.
    I need somebody's help that I'm trying to create a CDC class library
    which's refer to another CDC class library.
    The develop environment's Nokia Series 80 Platform SDK for Symbian OS, for Java, Personal Profile
    which's emulator of J2ME(CDC) with NetBeans IDE 6.0.1 for Mobility.
    First of alll, I created class that will be used from other library.
    The library name calls core here.
    Second of all, I try to build another class library which's refer to core library.
    then, I get error that as below.
    Symbol not found.
    Place:java.lang.NoClassDefFoundError Class
    method(XXXX.class.getName());--------> XXXX is the class which's include of core library.
    Error: can't detect initCause method.
    I confirmed that the "project.properties" file of core lib includes "build.classes.excludes"
    and "project.properties" file of target lib includes "libs.classpath".
    I have no idea to resolve this problem.
    Does anyone know that how to resolve it?
    Edited by: fc3srx7m on Mar 4, 2008 6:20 PM

    I resolved myself that the reason was "class.getName()" does not supported on CDC 1.0.(Maybe)
    Therefore, I use literal insted of "class.getName()".
    That's all.
    Thank you.

  • How many users for remote connection can I  create, from support SAP

    Dear all
    I have a doubt with how many users can be created in my system ERP 6.0 for the remote connection, for the error product  messages on the marketplace SAP,without this counts as user license.
    I have not found any notes or documents from SAP to explain this.
    I appreciate your help.
    Best Regards,
    Erika

    Ok...I will reply to myself. I can use more than 10 simultaneous connection, using vnc.

  • From abstract class to public class

    I am developing a editor base application...wondering that how to cancel the abstract class and put all the abstract class methods into the public class..?? thanks

    Is this a C++ question? If so, you should post it in the C++ forum. If it is a Java question, post in the Java forum.
    In either case, please make your question more specific. It sounds like all you have to do is copy the functions from the abstract class to the derived class, remove the dependency on the abstract class, and delete the abstract class from the source code. Presumably that is not what you are asking.

  • Method inheritence from abstract classes, and arguments

    I'm trying to do something a little weird. I'm writing a pretty complicated wrapper/adapter for two platforms, and I'd like to have an abstract method passed on to child classes, but with the type of the single argument specified by the child class. Is this possible?
    Example
    public abstract class AbstractParent {
    public abstract void foo([ambiguousType] arg);
    public class ChildOne extends AbstractParent {
    public void foo(TypeA arg) {
    //body
    public class ChildTwo extends AbstractParent {
    public void foo(TypeB arg) {
    //body
    }TypeA and TypeB have no common supertype beyond Object, and I'd rather not just do instanceof checks and throw errors. Does anyone know of a solution? Can I elaborate any better?

    Perhaps you could use generics?
        public abstract class AbstractParent<E> {
            public abstract void foo(E arg);
        public abstract class ChildOne extends AbstractParent<String> {
            public void foo(String arg) {
        public abstract class ChildTwo extends AbstractParent<Integer> {
            public void foo(Integer arg) {
        }

  • Can't create client proxy classes from WebLogic-generated WSDL file

    We have a web service that we used to generated a WSDL file. We then used clientgen
    to try and create the client proxy classes from the WSDL. This failed. Doesn't
    it seem reasonable that if WebLogic creates a WSDL that WebLogic should also be
    able to consume that WSDL?

    Can you please post the wsdl?
    Regards,
    -manoj
    http://manojc.com
    "Robert" <[email protected]> wrote in message
    news:40db0bc0@mktnews1...
    >
    We have a web service that we used to generated a WSDL file. We then usedclientgen
    to try and create the client proxy classes from the WSDL. This failed.Doesn't
    it seem reasonable that if WebLogic creates a WSDL that WebLogic shouldalso be
    able to consume that WSDL?

  • How many view object instances can create from Single Entity ?

    Hi All,
    JDev Ver : 11.1.1.5
    I want to How Many view objects can i create from the single entitiy ?
    Is there any limit ?
    Thanks,
    Gopinath

    No, there is no limit

  • Entity Instances created from backend inaccessible during interview session

    Hi,
    Is it possible to access entity instances which are created from back end, during an interview session?
    I am creating the entity instances and setting some of its attributes from the back end. But when I try to access these instances on screen to set the rest of its attributes, I get the following error -
    com.oracle.determinations.interview.engine.exceptions.InterviewEngineException: Entity Instance does not exist in model

    Yes it is possible to access the entity instances held in the session. However, in an interview session you should never change the state of the session directly, but rather use the setData methods provided by the Interview API or write a data adaptor plugin. The error message you are receiving is cause by the reason it states, namely the entity instance you're asking for does not exist in the session. If you are adding entity instances by modifying the session directly rather than using the Interview API, it's likely that those entities their associated attributes are being lost and hence the error.
    If you can provide more details on what it is that you are trying to do I can help point you in the right direction.
    Thanks,
    Kristy

  • How can i create multiple apple ids from the same mac

    There seems to be a limit on how many apple ids can be created from the same cpu. Trying to create 100 apple ids for a client to use on ipads distributed to employees i found i could only create three or four before i got the message account cannot be created, contact itunes support. Had the same problem creating multiple itunes accounts through the App Store.

    I found this discussion because I need to create dozens of Apple IDs for the faculty and staff of the school for which I'm the IT Director.
    This is weak.
    Apple, PLEASE upgrade the Apple ID system so it represents the current needs and paradigm.
    What am I thinking, Apple (like Google) don't follow user discussion forums, except by accident when an employee sees something and is motivated enough to carry the water for users in need.

  • Calling a method from abstarct class

    Hi Experts,
    Am working on ABAP Objects.
    I have created an Abstract class - with method m1.
    I have implemented m1.
    As we can not instantiate an abstract class, i tried to call the method m1 directly with class name.
    But it it giving error.
    Please find the code below.
    CLASS c1 DEFINITION ABSTRACT.
      PUBLIC SECTION.
        DATA: v1 TYPE i.
        METHODS: m1.
    ENDCLASS.                    "c1 DEFINITION
    CLASS c1 IMPLEMENTATION.
      METHOD m1.
        WRITE: 'You called method m1 in class c1'.
      ENDMETHOD. "m1
    ENDCLASS.                    "c1 IMPLEMENTATION
    CALL METHOD c1=>m1.
    Please tell me what is wrong and how to solve this problem.
    Thanks in Advance.

    Micky is right, abstract means not to be instantiated. It is just a "template" which you can use for all subsequent classes. I.e you have general abstract class vehicle . For all vehicles you will have the same attributes like speed , engine type ,  strearing , gears etc and methods like start , move etc.
    In all subsequent classes (which inherit from vehicle) you will have more specific attributes for each. But all of these classes have some common things (like the ones mentioned above), so they use abstract class to define these things for all of them.
    Moreover there is no sense in creating instance (real object) of class vehicle . What kind of physical object would vehicle be? there is no such object in real world, right? For this we need to be more precise, so we create classes which use this "plan" for real vehicles. So the abstract class here is only to have this common properties and behaviour defined in one place for all objects which will have these. Abstract object however cannot be created per se. You can only create objects which are lower in hierarchy (which are specific like car , ship, bike etc).
    Hope this claryfies what we need abstract classes for.
    Regards
    Marcin

  • Why does this abstract class and method work without implement it?

    hi,
    I have seen many times that in some examples that there are objects made from abstract classes directly. However, in all books, manual and tutorials that I've read explain that we MUST implement those methods in a subclass.
    An example of what I'm saying is the example code here . In a few words that example makes Channels (java.nio.channel) and does operations with them. My problem is in the class to make this channels, because they used the ServerSockeChannel class and socket() method directly despite they are abstracts.
       // Create a new channel: if port == 0, FileChannel on /dev/tty, else
       // a SocketChannel from the first accept on the given port number
    private static ByteChannel newChannel (int netPort)
          throws Exception
          if (netPort == 0) {
             FileInputStream fis = new FileInputStream ("/dev/tty");
             return (fis.getChannel());
          } else {
    //CONFLICT LINES
             ServerSocketChannel ssc = ServerSocketChannel.open(); //<--I have never thought do that!! Anyway, how it is static method may work.
             ssc.socket().bind (new InetSocketAddress (netPort)); //<--but here, this method (socket) is abstract. WHY RETURN A SOCKET????????  this mehod should be empty by default.
             System.out.print ("Waiting for connection on port "
                + netPort + "...");
             System.out.flush();
             ByteChannel channel = ssc.accept();
             ssc.close();
             System.out.println ("Got it");
             return (channel);
       } I test this code and works fine. So why can it be??
    Also, I read that the abstract classes can't have static methods. Is it true???
    Please Help!!
    PS: i have seen this kind of code many times. So i feel that I don't understand how its really the abstract methods are made.
    PS2: I understand that obviously you don't do something like this: *"obj = new AbstractClass(); "*. I dont understand how it could be: ServerSocketChannel ssc = ServerSocketChannel.open(); and the compiler didn't warn.

    molavec wrote:
    ServerSocketChannel ssc = ServerSocketChannel.open(); //<--I have never thought do that!! Anyway, how it is static method may work.
    The static method creates an instance of a class which extends ServerSocketChannel, but is actually another non-abstract class.I thought that, but reading the documentation I saw that about open() method:
    Opens a server-socket channel.
    The new channel is created by invoking the openServerSocketChannel method of the system-wide default SelectorProvider object.
    The new channel's socket is initially unbound; it must be bound to a specific address via one of its socket's bind methods before connections can be accepted.
    ...and the problem is the same openServerSocketChannel is abstract, so i don't understand how it could return a ServerSocketChannel.There is a concrete implementation class that has implemented that method.
    I guess that really the open() method use a SelectorProvider's subclase but it doesn't appear in the doc.It doesn't need to. First, you don't care about those implementation details, and second, you know that if the class is abstract, it must use some concrete subclass.
    Ok, I speak Spanish by default (<-- this sounds like "I am a machine", ^_^' ). So, I didn't know how to say that the method would be {}. Is there a way to say that?? I recommendable for me to know, for the future questions o answers.Not sure what you're saying here. But the other respondent was trying to explain to you the difference between an abstract method and an empty method.
    // abstract method
    public abstract void foo();
    // empty method
    public void bar() {
    Which class does extend ServerSocketChannel? I can not see it.It may be a package-private class or a private nested class. There's no need to document that specific implementation, since you never need to use it directly.

Maybe you are looking for

  • Parallel processing of mass data : sy-subrc value is not changed

    Hi, I have used the Parallel processing of mass data using the "Start New Task" . In my function module I am handling the exceptions and finally raise the application specific old exception to be handled in my main report program. Somehow the sy-subr

  • Extended Notifications with Desicion Comments

    Hi all, We have a requirement to have a prompt for user comments when ever user takes a decision in the Extended notifications. The user will receive a mail to his outlook with the approve and reject links and we want to have some setup to ask the us

  • Nokia lumia 920 only showing as a camera on Window...

    my lumia 920 is only showing as a camera when connected to my Windows xp, when you open the camera file there are four files inside but you can't downloads any files into them. can someone help me please. has anyone also had this problem

  • Please explain why this happened - and what I should do about it!

    Hello!  When I clicked on this link elsewhere in the Apple Communities  https://discussions.apple.com/message/15579763#15579763 I was whisked away to see THIS message    -    can anyone explain why and advise of any action I should take? Thanks, Davi

  • WRT54GS v.6 cannot enable security mode.

    hey guys, I've tried everything, even a firmware upgrade and I've been using IE and I cannot enable any security.  anytime I try to select WPA or WEP or anything it refreshes automatically back to "disabled".  I've tried multiple resets as well and a