DESTRUCTOR

Does anybody know, if and when SAP will allow the implementation of DESTRUCTOR in ABAP-OO? Currently, one is only allowed to call an C-Function (Kernel-Function) within the DESTRUCTOR?
see SAP-Note [168703|https://websmp105.sap-ag.de/~form/handler?_APP=01100107900000000342&_EVENT=REDIR&_NNUM=168703&_NLANG=E]

Hi Mike,
I think we won't be able to implement DESTRUCTOR in ABAP Objects it because ABAP Objects was designed to be simple than Java and C++, and to omit complex concepts that lack in benefits such destructors !
"Currently ABAP Objects does not include any destructor, in which a regular ABAP processing block can be programmed. This means that the destructor makes it possible to call only a C routine name when an object is deleted. The routine must exist in the kernel in order that no syntax error occurs."
(The C Destructor Help information)
Don't forget to close this Thread when your question be answered !
Regards,
Marcelo Ramos

Similar Messages

  • ABAP OO: How to implement a Destructor

    Hello.
    I implemented a ABAP-OO-Class, which supports (above others) the following methods:
    NEW -> Create new Object in DB
    DELETE -> Delete Object from DB
    In case the method DELETE is called i want to 'destroy' the object instance of this class. Currently i worked around this problem by CLEARing all instance attributes.
    Is there a way to implement a DESTRUCTOR, which really destroys the object?
    MIKE

    HI Mike,
    Check these Links out
    <b>METHOD DESTRUCTOR
    Re: Any possibility to implement a destructor in abap-objects
    Regards,
    Santosh

  • Any possibility to implement a destructor in abap-objects

    we have a class that when generated creates open a logger-handle via the normal SAP functions. If this class gets destroyed (i.e. if the session in this case is closed) there is no return to any calling point possible.
    So what I would need here would be a destructor in which I could close the log-handle again and this way exit with all things done in an orderly way.
    Dumb thing is couldnt find anything about destructors in AbapObjects - so fear they cant be dont? Or am I hopefully wrong on this?

    thx for the answer but I think theres some misunderstanding...dont want a method from outside I can call to destroy my object (free)...I need a method (like the counterpart to a constructor) that gets automatically called WHEN the instance is destroyed (like the constructor is when the instance is created).
    As I said problem is, when the class gets destroyed I dont have the possibility outside of it to e.g. close the logger-handle.

  • Destructor method in Forte...

    Hi all,
    Does anyone know of a "destructor" method in Forte that will be called when
    an object is destroyed?
    Thanks,
    -Deva

    I'd have to agree with Dave Campbell - let Forte house-keep.
    If you can not wait for an object to lose scope and then for the garbage
    collector, I would use the destructive-like methods such as Close(),
    RecycleMemory(), ect. that usually come with the object and/or it's parent
    classes. Forte is very C++ like, except in the object creation/destruction
    arena.
    Kelsey PetrychynSaskTel Technical Analyst
    ITM - Technology Solutions - Distributed Computing
    Tel (306) 777 - 4906, Fax (306) 359 - 0857
    Internet:kelsey.petrychynSasktel.sk.ca
    Quality is not job 1. It is the only job!
    ---------------------- Forwarded by Kelsey Petrychyn/SaskTel/CA on 10/17/2000
    01:04 PM ---------------------------
    "Dave Campbell" <Dave.CampbellCaroSys.com> on 10/17/2000 12:51:33 PM
    Please respond to Dave.CampbellCaroSys.com
    To: forte-userslists.xpedior.com
    cc: (bcc: Kelsey Petrychyn/SaskTel/CA)
    Subject: (forte-users) destructor method in Forte...
    I don't think there is a destructor method that developers can call
    directly.
    garbage collection is done by forte all by itself.
    Although, you can on the Window side call Self.Window.RecycleMemory();
    to expedite this collection of Nil objects and other "finished" objects
    Regards,
    Dave Campbell
    Consultant,
    Caro Systems Inc.
    75 Sherbourne St., Suite 112
    Toronto Ontario M5A 2P9
    WebSite: http://www.carosys.com
    Phone:(416) 628-5675 Or Mailto:Dave.CampbellCaroSys.com
    -----Original Message-----
    From: Sagar, Devasena [mailto:DSagaradvanta.com]
    Sent: October 17, 2000 2:29 PM
    To: forte-userslists.xpedior.com
    Subject: (forte-users) destructor method in Forte...
    Hi all,
    Does anyone know of a "destructor" method in Forte that will be called when
    an object is destroyed?
    Thanks,
    -Deva
    For the archives, go to: http://lists.xpedior.com/forte-users and use
    the login: forte and the password: archive. To unsubscribe, send in a new
    email the word: 'Unsubscribe' to: forte-users-requestlists.xpedior.com
    For the archives, go to: http://lists.xpedior.com/forte-users and use
    the login: forte and the password: archive. To unsubscribe, send in a new
    email the word: 'Unsubscribe' to: forte-users-requestlists.xpedior.com

  • How does java support the concept of destructor?

    How does java support the concept of destructor?

    @KunalSurana: before you flood the forum with basic questions, do us a favour and read.
    [Sun's basic Java tutorial|http://java.sun.com/docs/books/tutorial/]
    [Sun's New To Java Center|http://java.sun.com/learning/new2java/index.html]
    Includes an overview of what Java is, instructions for setting up Java, an intro to programming (that includes links to the above tutorial or to parts of it), quizzes, a list of resources, and info on certification and courses.
    jGuru
    A general Java resource site. Includes FAQs, forums, courses, more.
    JavaRanch
    To quote the tagline on their homepage: "a friendly place for Java greenhorns." FAQs, forums (moderated, I believe), sample code, all kinds of goodies for newbies. From what I've heard, they live up to the "friendly" claim.
    [Yawmarks List|http://forums.devshed.com/java-help-9/resources-for-learning-java-249225.html]
    [The Java Developers Almanac|http://www.amazon.com/exec/obidos/tg/detail/-/0201752808?v=glance]
    [http://javaalmanac.com|http://javaalmanac.com]
    Bruce Eckel's [Thinking in Java(Available online.)|http://mindview.net/Books/DownloadSites]
    Joshua Bloch's [Effective Java|http://www.amazon.co.uk/exec/obidos/Author=Bloch,%20Josh]
    Bert Bates and Kathy Sierra's [Head First Java|http://www.amazon.com/exec/obidos/tg/detail/-/0596004656?v=glance ]
    James Gosling's [The Java Programming Language|http://www.bookpool.com/sm/0321349806]
    Gosling is the creator of Java. It doesn't get much more authoritative than this.
    Joshua Bloch and Neal Gafter [Java Puzzlers.|http://www.javapuzzlers.com/]

  • IDBase_UI_Dialog::Destructor not always called when dialog exits?

    Hi,
    We're having an intermittent issue with one of our dialogs on CC 2014 on Mac 10.8.  It's a Moveable Modal dialog and sometimes when it is closed, the next time it opens the dialog come up but IDialog::Open returns immediately rather than blocking as you would expect for a Modal dialog.
    Having used the trace, what appears to be happening is that when the dialog is closed, when it works properly the last thing that InDesign does is:
    DVModalDialogWindow::Destructor
    DVWindow::ReleaseWindow deleting drover OS_Window for 3b50e600
    IDBase_UI_Dialog::Destructor
    but when it doesn't work, these three lines do not appear in the trace.  Could we be doing something that would cause this?
    Can anyone shed some light on this?
    Thanks,
    Dan Tate

    I have found a workaround for this: when the IDialog::Open returns immediately, the IDialog::IsOpen returns true, so I can trap it.  If I then call IDialog::SetDeleteOnClose(true) and then IDialog::Close, then the dialog does close properly and opens correctly the next time.
    I'd still like to know why I am getting into this state in the first place though.
    For further information, this seems to happen less frequently (if at all) on CC 2014 10.1, but happens fairly regularly on 10.0 - was anything changed in this area between the two versions?
    Thanks,
    Dan Tate

  • Porting from win to mac / expected constructor destructor or type conversion before

    I am porting a plugin that works well with CS3/4/5 on Windows to CS3 on Mac.
    I am able to compile the SDK samples with XCode. My plugin also compiles with XCode if i remove one cpp file from the project. If i try to compile it with the file (actioncomponent.cpp) compiling fails with the error:
    expected constructor destructor or type conversion before .....
    I tried to trace the error by commenting out ceveral includes and functions in that file. The error then point's to another place in the file itself or in one included in it, the error is the same.
    I generated the project with dollyx, added my .fr, compiled it, added the .fr.rsrc, added source files and built it.
    Since this is my first Indesign plugin for Mac I am sure that i miss something general.
    Any suggestions?

    I checked my code against every SDK sample where context/session is used and cannot find any difference. I also took a sample project, included my sources what resulted in the same error messages.
    One of them:
    Checking Dependencies
    CompileC build/myPluginName.build/Default/Release.build/Objects-normal/ppc/myPluginNameActionCompo nent.o /Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/../../../source/sdksa mples/myPluginName/myPluginNameActionComponent.cpp normal ppc c++ com.apple.compilers.gcc.4_0
        cd /Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj
        /Developer/usr/bin/gcc-4.0 -x c++ -arch ppc -pipe -Wno-trigraphs -fno-exceptions -fpascal-strings -fasm-blocks -O3 -Werror -Wreturn-type -Wunused-value -DMACINTOSH -DBIB_NO_THROW -fmessage-length=0 -mtune=G5 -fvisibility=hidden -fvisibility-inlines-hidden -fno-threadsafe-statics -Wno-deprecated-declarations -mmacosx-version-min=10.4 -gdwarf-2 -I/Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/build/myPluginName. build/Default/Release.build/myPluginName.hmap -Wno-deprecated -F/Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/../release/sdk -F../../../build/mac/release/packagefolder/contents/macos -F../../../build/mac/release/packagefolder/contents/Frameworks -I/Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/../release/sdk/incl ude -I/Developer/SDKs/MacOSX10.4u.sdk/Developer/Headers/FlatCarbon -I../../../external/adobesourcelibrary/third_party/boost_tp/boost -I../../../external/afl/includes -I../../../source/precomp/common -I../../../source/precomp/msvc -I../../../source/public/includes -I../../../source/public/interfaces/architecture -I../../../source/private/includes/architecture -I../../../source/private/interfaces/architecture -I../../../source/public/includes/utils -I../../../source/public/interfaces/utils -I../../../source/precomp/msvc -I../../../source/public/interfaces/xmedia -I../../../source/public/interfaces/ui -I../../../source/public/interfaces/tables -I../../../source/public/interfaces/text -I../../../source/public/interfaces/graphics -I../../../source/public/components/widgetbin/includes -I../../../source/public/interfaces/workgroup -I../../../source/public/interfaces/interactive -I../../../source/public/interfaces/interactive/ui -I../../../source/public/interfaces/colormgmt -I../../../source/public/interfaces/utils -I../../../source/public/interfaces/incopy -I../../../source/public/interfaces/layout -I../../../source/public/interfaces/architecture -I../../../source/public/interfaces/cjk -I../../../source/precomp/common -I../../../source/public/includes -I../../../source/public/components/publiclib/plugins -I../../../source/public/components/publiclib/files -I../../../source/public/components/publiclib/objectmodel -I../../../external/boost -I../../../source/sdksamples/common -I../../../external/afl/includes -I../../../source/sdksamples/myPluginName -I/Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/build/myPluginName. build/Default/Release.build/DerivedSources -isysroot /Developer/SDKs/MacOSX10.4u.sdk -include build/SharedPrecompiledHeaders/Release/PluginPrefix-hkopdumatdlxfjbkpugezhwgmujv/PluginPr efix.pch -c /Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/../../../source/sdksa mples/myPluginName/myPluginNameActionComponent.cpp -o /Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/build/myPluginName.bu ild/Default/Release.build/Objects-normal/ppc/myPluginNameActionComponent.o
    ../../../source/public/includes/KeyValuePair.h:36: error: expected constructor, destructor, or type conversion before 'template'
    ../../../source/public/includes/KeyValuePair.h:82: error: expected ',' or '...' before '<' token
    ../../../source/public/includes/KeyValuePair.h:82: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/includes/KeyValuePair.h:82: error: 'bool operator==(int)' must have an argument of class or enumerated type
    ../../../source/public/includes/KeyValuePair.h:82: error: 'bool operator==(int)' must take exactly two arguments
    ../../../source/public/includes/KeyValuePair.h: In function 'bool operator==(int)':
    ../../../source/public/includes/KeyValuePair.h:84: error: '__x' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h:84: error: '__y' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: At global scope:
    ../../../source/public/includes/KeyValuePair.h:97: error: expected ',' or '...' before '<' token
    ../../../source/public/includes/KeyValuePair.h:97: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/includes/KeyValuePair.h:97: error: 'bool operator==(int)' must have an argument of class or enumerated type
    ../../../source/public/includes/KeyValuePair.h:97: error: 'bool operator==(int)' must take exactly two arguments
    ../../../source/public/includes/KeyValuePair.h:97: error: redefinition of 'template<class _T1, class _T2> bool operator==(int)'
    ../../../source/public/includes/KeyValuePair.h:82: error: 'template<class _T1, class _T2> bool operator==(int)' previously declared here
    ../../../source/public/includes/KeyValuePair.h: In function 'bool operator==(int)':
    ../../../source/public/includes/KeyValuePair.h:99: error: '__x' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h:99: error: '__y' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: At global scope:
    ../../../source/public/includes/KeyValuePair.h:112: error: expected ',' or '...' before '<' token
    ../../../source/public/includes/KeyValuePair.h:112: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/includes/KeyValuePair.h: In function 'bool operator==(const _T1&, int)':
    ../../../source/public/includes/KeyValuePair.h:114: error: '__x' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: At global scope:
    ../../../source/public/includes/KeyValuePair.h:124: error: expected ',' or '...' before '<' token
    ../../../source/public/includes/KeyValuePair.h:124: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/includes/KeyValuePair.h:124: error: 'bool operator<(int)' must have an argument of class or enumerated type
    ../../../source/public/includes/KeyValuePair.h:124: error: 'bool operator<(int)' must take exactly two arguments
    ../../../source/public/includes/KeyValuePair.h: In function 'bool operator<(int)':
    ../../../source/public/includes/KeyValuePair.h:126: error: '__x' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h:126: error: '__y' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: At global scope:
    ../../../source/public/includes/KeyValuePair.h:135: error: expected ',' or '...' before '<' token
    ../../../source/public/includes/KeyValuePair.h:135: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/includes/KeyValuePair.h:135: error: 'bool operator<(int)' must have an argument of class or enumerated type
    ../../../source/public/includes/KeyValuePair.h:135: error: 'bool operator<(int)' must take exactly two arguments
    ../../../source/public/includes/KeyValuePair.h:135: error: redefinition of 'template<class _T1, class _T2> bool operator<(int)'
    ../../../source/public/includes/KeyValuePair.h:124: error: 'template<class _T1, class _T2> bool operator<(int)' previously declared here
    ../../../source/public/includes/KeyValuePair.h: In function 'bool operator<(int)':
    ../../../source/public/includes/KeyValuePair.h:137: error: '__x' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h:137: error: '__y' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: At global scope:
    ../../../source/public/includes/KeyValuePair.h:146: error: expected ',' or '...' before '<' token
    ../../../source/public/includes/KeyValuePair.h:146: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/includes/KeyValuePair.h: In function 'bool operator<(const _T1&, int)':
    ../../../source/public/includes/KeyValuePair.h:148: error: '__x' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: At global scope:
    ../../../source/public/includes/KeyValuePair.h:157: error: expected ',' or '...' before '<' token
    ../../../source/public/includes/KeyValuePair.h:157: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/includes/KeyValuePair.h:157: error: 'bool operator!=(int)' must have an argument of class or enumerated type
    ../../../source/public/includes/KeyValuePair.h:157: error: 'bool operator!=(int)' must take exactly two arguments
    ../../../source/public/includes/KeyValuePair.h: In function 'bool operator!=(int)':
    ../../../source/public/includes/KeyValuePair.h:158: error: '__x' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h:158: error: '__y' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: At global scope:
    ../../../source/public/includes/KeyValuePair.h:167: error: expected ',' or '...' before '<' token
    ../../../source/public/includes/KeyValuePair.h:167: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/includes/KeyValuePair.h:167: error: 'bool operator>(int)' must have an argument of class or enumerated type
    ../../../source/public/includes/KeyValuePair.h:167: error: 'bool operator>(int)' must take exactly two arguments
    ../../../source/public/includes/KeyValuePair.h: In function 'bool operator>(int)':
    ../../../source/public/includes/KeyValuePair.h:168: error: '__y' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h:168: error: '__x' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: At global scope:
    ../../../source/public/includes/KeyValuePair.h:177: error: expected ',' or '...' before '<' token
    ../../../source/public/includes/KeyValuePair.h:177: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/includes/KeyValuePair.h:177: error: 'bool operator<=(int)' must have an argument of class or enumerated type
    ../../../source/public/includes/KeyValuePair.h:177: error: 'bool operator<=(int)' must take exactly two arguments
    ../../../source/public/includes/KeyValuePair.h: In function 'bool operator<=(int)':
    ../../../source/public/includes/KeyValuePair.h:178: error: '__y' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h:178: error: '__x' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: At global scope:
    ../../../source/public/includes/KeyValuePair.h:187: error: expected ',' or '...' before '<' token
    ../../../source/public/includes/KeyValuePair.h:187: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/includes/KeyValuePair.h:187: error: 'bool operator>=(int)' must have an argument of class or enumerated type
    ../../../source/public/includes/KeyValuePair.h:187: error: 'bool operator>=(int)' must take exactly two arguments
    ../../../source/public/includes/KeyValuePair.h: In function 'bool operator>=(int)':
    ../../../source/public/includes/KeyValuePair.h:188: error: '__x' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h:188: error: '__y' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: At global scope:
    ../../../source/public/includes/KeyValuePair.h:197: error: expected initializer before '<' token
    ../../../source/public/includes/KeyValuePair.h:225: error: expected ',' or '...' before '<' token
    ../../../source/public/includes/KeyValuePair.h:225: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/includes/KeyValuePair.h: In member function 'bool KeyMatchPredicate<Key, Value>::operator()(int)':
    ../../../source/public/includes/KeyValuePair.h:225: error: 'x' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: At global scope:
    ../../../source/public/includes/KeyValuePair.h:252: error: expected ',' or '...' before '<' token
    ../../../source/public/includes/KeyValuePair.h:252: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/includes/KeyValuePair.h: In member function 'bool ValueMatchPredicate<Key, Value>::operator()(int)':
    ../../../source/public/includes/KeyValuePair.h:252: error: 'x' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: In function 'void InsertKeyValue(Container&, const Key&, const Value&)':
    ../../../source/public/includes/KeyValuePair.h:282: error: 'KeyValuePair' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h:282: error: expected primary-expression before ',' token
    ../../../source/public/includes/KeyValuePair.h:282: error: expected primary-expression before '>' token
    ../../../source/public/includes/KeyValuePair.h: In function 'void InsertOrReplaceKeyValue(Container&, const Key&, const Value&)':
    ../../../source/public/includes/KeyValuePair.h:298: error: 'KeyValuePair' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h:298: error: expected primary-expression before ',' token
    ../../../source/public/includes/KeyValuePair.h:298: error: expected primary-expression before '>' token
    ../../../source/public/includes/KeyValuePair.h: In function 'int32 InsertKeyValueInSorted(Container&, const Key&, const Value&)':
    ../../../source/public/includes/KeyValuePair.h:326: error: expected initializer before '<' token
    ../../../source/public/includes/KeyValuePair.h:328: error: 'el' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h: In function 'int32 InsertOrReplaceKeyValueInSorted(Container&, const Key&, const Value&)':
    ../../../source/public/includes/KeyValuePair.h:345: error: 'KeyValuePair' was not declared in this scope
    ../../../source/public/includes/KeyValuePair.h:345: error: expected primary-expression before ',' token
    ../../../source/public/includes/KeyValuePair.h:345: error: expected primary-expression before '>' token
    ../../../source/public/interfaces/architecture/IActiveContext.h: At global scope:
    ../../../source/public/interfaces/architecture/IActiveContext.h:56: error: ISO C++ forbids declaration of 'KeyValuePair' with no type
    ../../../source/public/interfaces/architecture/IActiveContext.h:56: error: expected ';' before '<' token
    ../../../source/public/interfaces/architecture/IActiveContext.h:57: error: 'ContextInfo' was not declared in this scope
    ../../../source/public/interfaces/architecture/IActiveContext.h:57: error: template argument 1 is invalid
    ../../../source/public/interfaces/architecture/IActiveContext.h:57: error: template argument 2 is invalid
    ../../../source/public/interfaces/architecture/ISelectionMessages.h:59: error: 'KeyValuePair' was not declared in this scope
    ../../../source/public/interfaces/architecture/ISelectionMessages.h:59: error: template argument 1 is invalid
    ../../../source/public/interfaces/architecture/ISelectionMessages.h:59: error: expected unqualified-id before '>' token
    ../../../source/public/interfaces/architecture/ISelectionMessages.h:172: error: ISO C++ forbids declaration of 'SuiteBroadcastData' with no type
    ../../../source/public/interfaces/architecture/ISelectionMessages.h:172: error: 'SuiteBroadcastData' declared as a 'virtual' field
    ../../../source/public/interfaces/architecture/ISelectionMessages.h:172: error: expected ';' before '*' token
    ../../../source/public/interfaces/architecture/ISelectionMessages.h:366: error: 'KeyValuePair' was not declared in this scope
    ../../../source/public/interfaces/architecture/ISelectionMessages.h:366: error: template argument 1 is invalid
    ../../../source/public/interfaces/architecture/ISelectionMessages.h:366: error: expected unqualified-id before '>' token
    ../../../source/public/interfaces/architecture/ISelectionManager.h:166: error: 'SuiteBroadcastData' has not been declared
    ../../../source/public/interfaces/architecture/ISelectionManager.h:212: error: 'SuiteBroadcastData' has not been declared
    /Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/../../../source/sdksam ples/myPluginName/myPluginNameActionComponent.cpp:43: error: definition of implicitly-declared 'virtual myPluginNameActionComponent::~myPluginNameActionComponent()'
    CompileC build/myPluginName.build/Default/Release.build/Objects-normal/i386/myPluginNameDialogObse rver.o /Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/../../../source/sdksa mples/myPluginName/myPluginNameDialogObserver.cpp normal i386 c++ com.apple.compilers.gcc.4_0
        cd /Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj
        /Developer/usr/bin/gcc-4.0 -x c++ -arch i386 -pipe -Wno-trigraphs -fno-exceptions -fpascal-strings -fasm-blocks -O3 -Werror -Wreturn-type -Wunused-value -DMACINTOSH -DBIB_NO_THROW -fmessage-length=0 -fvisibility=hidden -fvisibility-inlines-hidden -fno-threadsafe-statics -Wno-deprecated-declarations -mmacosx-version-min=10.4 -gdwarf-2 -I/Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/build/myPluginName. build/Default/Release.build/myPluginName.hmap -DMACTEL_SKIP -Wno-deprecated -F/Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/../release/sdk -F../../../build/mac/release/packagefolder/contents/macos -F../../../build/mac/release/packagefolder/contents/Frameworks -I/Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/../release/sdk/incl ude -I/Developer/SDKs/MacOSX10.4u.sdk/Developer/Headers/FlatCarbon -I../../../external/adobesourcelibrary/third_party/boost_tp/boost -I../../../external/afl/includes -I../../../source/precomp/common -I../../../source/precomp/msvc -I../../../source/public/includes -I../../../source/public/interfaces/architecture -I../../../source/private/includes/architecture -I../../../source/private/interfaces/architecture -I../../../source/public/includes/utils -I../../../source/public/interfaces/utils -I../../../source/precomp/msvc -I../../../source/public/interfaces/xmedia -I../../../source/public/interfaces/ui -I../../../source/public/interfaces/tables -I../../../source/public/interfaces/text -I../../../source/public/interfaces/graphics -I../../../source/public/components/widgetbin/includes -I../../../source/public/interfaces/workgroup -I../../../source/public/interfaces/interactive -I../../../source/public/interfaces/interactive/ui -I../../../source/public/interfaces/colormgmt -I../../../source/public/interfaces/utils -I../../../source/public/interfaces/incopy -I../../../source/public/interfaces/layout -I../../../source/public/interfaces/architecture -I../../../source/public/interfaces/cjk -I../../../source/precomp/common -I../../../source/public/includes -I../../../source/public/components/publiclib/plugins -I../../../source/public/components/publiclib/files -I../../../source/public/components/publiclib/objectmodel -I../../../external/boost -I../../../source/sdksamples/common -I../../../external/afl/includes -I../../../source/sdksamples/myPluginName -I/Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/build/myPluginName. build/Default/Release.build/DerivedSources -isysroot /Developer/SDKs/MacOSX10.4u.sdk -include build/SharedPrecompiledHeaders/Release/PluginPrefix-ajenzpjyosjkeodzeqpqmcfnvjiw/PluginPr efix.pch -c /Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/../../../source/sdksa mples/myPluginName/myPluginNameDialogObserver.cpp -o /Volumes/daten/adobe_indesign_cs3_products_sdk_504mac/build/mac/prj/build/myPluginName.bu ild/Default/Release.build/Objects-normal/i386/myPluginNameDialogObserver.o
    What am I doing wrong?

  • Core Dump in RWCString destructor

    I have written a program on occasionally core dump.
    The core dump are in destructor in RWCString.
    Moreover, I have a case that the RWCString is wrongly put to other cache. It is a mulit-threaded program.
    I have used -DRW_MULTI_THREAD -mt options. I also need /usr/ucblib and -lc. Not sure if there is any conflict
    I am using Forte C++ 7.0 with RWSP_TOOLS 4.0.
    It is very hard to simulate the problem.
    Is there anybody having experience or idea on some core dump regarding RWCString?

    Sun doesn't have a product called "Forte C++ 7.0". You can find out the product name by running the "version" command out the same bin directory as the CC command.
    For example, if the CC command is /opt/SUNWspro/bin/CC, you can run /opt/SUNWspro/bin/version to find out the product name, and the version numbers of its components.
    Then go to the Sun Studio patch page
    http://developers.sun.com/prodtech/cc/downloads/patches/index.html
    and make sure you have the current patches for the compiler. Be sure also to get the current Solaris patches for the C++ runtime libraries (available from the same patch page).
    We can't provide direct support for 3rd-party libraries that we do not ship with the compiler. For help with RW SourcePro, you need to talk to Rogue Wave tech support.

  • Session bean destructor

    An application that I am working on has a bean that retains information about files uploaded by the user. The files are temporary, and need to be deleted at the end of the user's session-- hence the bean.
    <jsp:useBean id="fileupload" class="changehoursrequest.FileUpload" scope="session" />
    I was hoping that all that I would have to do is define a destructor in the bean (protected void finalize()) that deletes the temporary files. The destructor does what it's supposed to do, but doesn't seem to be called when the session ends. Is there a listener that I need to use? Am I doing something else wrong? Any suggestions?
    Here's the skelaton of the bean..
    public class FileUpload implements Enumeration
    public FileUpload(HttpServletRequest request) { }
    public FileUpload() {}
    public MultipartRequest getRequest() {}
    public void setRequest(HttpServletRequest request) { }
    public String getFileName() {}
    public String getFileType() {}
    public String getFileSystemName() {}
    public String getFileContents() {}
    public boolean hasMoreElements() {}
    public Object nextElement() {}
    // destroy temporary files
    protected void finalize() {}
    thanks,
    Bryan

    Interestingly, Websphere seems to be making its own determination on when to call valueUnbound. I set session timeout to 2 seconds and it took at least 30 seconds for websphere to sweep up.
    Websphere seems to have a lot of... personality.... I wonder if this is another part of its.... personality.
    -Bryan

  • Heap/stack, RVO, and destructors

    yes, wonderful topic name...
    I always wondered if the following (c++) code would work:
    std::string& foo()
    std::string* s = new std::string("bar");
    return *s;
    void test()
    std::string s = foo();
    } //does s get properly destroied here?
    the problem is as follows:
    in test(), s is declared as a stack (auto) variable...
    in foo(), s is created on the heap, and returned by reference, instead of by pointer...
    technically, this code is sound... however I don't know if proper destruction takes place... will RVO (return value optimization) take care of it?

    i3839 wrote:Perhaps I'm missing some hidden magick of references, but you said they were the same as pointers, and you made a new object and got a reference, no pointer in sight, so how can you blame pointers?
    that's excatly it... "new" returns a pointer... technically one should just [return string("foo");] without the "new" - and RVO then takes the construction into account so it's not done twice (once on the return line, then a copy constructor when the actual return does it's job)
    i3839 wrote:As for the memory management, what "internal memory management"? If you get data with new you need to free it yourself, either directly or indirectly (delete(this)?). All the memory management needs to be build into the classes as far as I can tell, or did C++ change so much recently?
    I was talking specifically about the STL... which is C++, as much as some people don't like to admit... anyone can write a class that has resource issues in general... hell you can do it with database connections in java (and C#)
    When you initialize an std::string, it calls new internally... and actually stores just the begin/end pointers, but it takes care or it's own resources...
    the pseudo-techincal term is "RAII" (Resource Acquisition is Initialization) - constructor calls new, destructor deletes... it's all internal... when consuming that class, you never need worry about memory management if done correctly.

  • No destructors?

    why don't we have the concept of destructors in java? albeit java takes care of garbage collecting the resources we've created while constructing the object, what if one needs to do some special action (like stopping/starting a new thread) when the object is destructed? all the garbage collection instructions are just a request to the jvm. i recently came across "shutdown hooks" in java... are they a workaround for destructors??

    Any thread can be stopped, function can be returned, loop can be broken. However, in java, a dynamically created object can not be destructed. You can do following to do so..
    make object null..
    JTextField tf = new JTextField( );
    tf = null; 
    System.gc( );  /* calls garbage collector, no surety can be given that your request would
    definitly be processed.*/

  • CComVariant, string destructors

    I've tried to find a definitive answer to this question but the WEB is full of text copies of half answers. So the CComVariant in the code below frees the string used to hold the text, right?
    CComVariant cvFname(szFilename);
    VARIANT result;
    VariantInit(&result);
    m_hr = OLEMethod(DISPATCH_METHOD, &result, m_pDocuments, L"Open", 1, cvFname);
    m_pActiveDocument = result.pdispVal;
    So when cvFName goes out of scope the memory for the string is releases,freed,...? I realise that szFilename is my responsability, but that is a different aspect.
    Have I understood correctly?
    http://www.ransen.com Cad and Graphics software

    On 3/23/2015 10:03 AM, "Owen Ransen" wrote:
         CComVariant cvFname(szFilename);
    So when cvFName goes out of scope the memory for the string is releases,freed,...?
    Depends on which string you mean by "the string" - there are at least two in this code. CComVariant's constructor makes a copy of szFilename. That copy is freed by CComVariant's destructor. szFilename is not in any way modified in the process.
    Igor Tandetnik

  • Destructors

    This is a stupid question but how do you make a class destructor in Java? The tilde '~' won't compile and I would like to perform some closing steps when the object is terminated. Please help...

    From the JDK1.3 dox:
    finalize
    protected void finalize()
    throws Throwable
    Called by the garbage collector on an object when garbage collection determines that there are no more references to the object. A subclass overrides the finalize method to dispose of system resources or to perform other cleanup.
    The general contract of finalize is that it is invoked if and when the JavaTM virtual machine has determined that there is no longer any means by which this object can be accessed by any thread that has not yet died, except as a result of an action taken by the finalization of some other object or class which is ready to be finalized. The finalize method may take any action, including making this object available again to other threads; the usual purpose of finalize, however, is to perform cleanup actions before the object is irrevocably discarded. For example, the finalize method for an object that represents an input/output connection might perform explicit I/O transactions to break the connection before the object is permanently discarded.
    The finalize method of class Object performs no special action; it simply returns normally. Subclasses of Object may override this definition.
    The Java programming language does not guarantee which thread will invoke the finalize method for any given object. It is guaranteed, however, that the thread that invokes finalize will not be holding any user-visible synchronization locks when finalize is invoked. If an uncaught exception is thrown by the finalize method, the exception is ignored and finalization of that object terminates.
    After the finalize method has been invoked for an object, no further action is taken until the Java virtual machine has again determined that there is no longer any means by which this object can be accessed by any thread that has not yet died, including possible actions by other objects or classes which are ready to be finalized, at which point the object may be discarded.
    The finalize method is never invoked more than once by a Java virtual machine for any given object.
    Any exception thrown by the finalize method causes the finalization of this object to be halted, but is otherwise ignored.
    Throws:
    Throwable - the Exception raised by this method

  • A destructor and a delete operator

    Hello,
    How to use the delete operator in JAVA?
    Also what is the syntax of writting destructor?
    class sample
    LinkedList Lists;
    sample()
    Lists = new LinkedList();
    ~sample()
    delete Lists;
    The above code doesn't work in JAVA.
    May I know the reason?

    You may want to null a reference in this case:
    class X {
        private BufferedImage image;
        public void setImage(URL url) throws IOException {
            image = null;
            image = ImageIO.read(url);
    }Without nulling the image reference, the JVM may find it's out of memory and gc while reading the new image.
    It may even find it has to expand memory to hold the new image.
    It may only realize the old image is eligable for collection after doing this and updating the image
    reference. (A smart JVM may realize that the last reference to the old image is about to disappear
    and hurry it along, but you can imagine situations where the detachment is more subtle.)
    Again there are a few instances where nulling a reference makes sense.

  • ST12: Unexpected destructor called

    Hi
    I have SunStudio12 on some Solaris 10 machine.
    CC -VCC: Sun C++ 5.9 SunOS_sparc 2007/05/03
    uname -aSunOS sungolem 5.10 Generic_125100-09 sun4u sparc SUNW,Sun-Fire-V250
    I have some problems with the following test program which terminates with core due to unexpected call of destructor:
    file:test.cc
    #include <iostream>
    using namespace std;
    class A
        char *_a;
      public:
        A(const char *t) { cout <<"A:ctor["<<t<<"]"<<endl; setdata(t);}
        virtual ~A() { cout <<"A:dtor["<<_a<<"]"<<endl; delete _a;_a = NULL;}
        void setdata(const char *data) {  _a = new char [strlen(data)+1];strcpy(_a,data);}
        const char * getdata() const { return _a;}
        A( const A &a){ cout <<"A:copy_ctor["<<a._a<<"]"<<endl;setdata(a._a);}
    bool operator == (const A&l, const A&r)
    {  return (strcmp(l.getdata(),r.getdata()) == 0?true:false);}
    int main()
        A c ("321");
        cout <<"1"<<endl;
        //cout << "compare"<<(c == A("123")?"true":"false")<<endl;
        cout <<"2"<<endl;
        bool f = false;
        bool isA = false;
        if(
         (f!= false)
         (c == (isA?A("123"):A("321"))))
         cout <<"3"<<endl;
        else
         cout <<"4"<<endl;
        cout <<"5"<<endl;
    }Compilation:
    CC -g -o test.x test.ccResult of execution:
    test.xA:ctor[321]
    1
    2
    A:dtor[Segmentation fault (core dumped)
    I tried with dbx:
    >
    1
    2
    A:dtor[signal SEGV (no mapping at the fault address) in strlen at 0xff030e38
    0xff030e38: strlen+0x0018:      ldub     [%o2], %o1
    Current function is A::~A
    11 virtual ~A() { cout <<"A:dtor["<<_a<<"]"<<endl; delete _a;_a = NULL;}
    (dbx) where
    [1] strlen(0x3, 0x21fd0, 0x3, 0xff37f4e8, 0x3, 0xff3798f0), at 0xff030e38
    [2] std::operator<<(0x21fd0, 0x3, 0xff37c194, 0x1, 0x0, 0x148), at 0xff3041e8
    =>[3] A::~A(this = 0xffbfcfcc), line 11 in "test.cc"
    [4] main(), line 33 in "test.cc"
    (dbx) print *this
    *this = {
    _a = 0x3 "<bad address 0x3>"
    Interesting thing - if you set optimization level to -xO3 then program works as expected:
    CC -xO3 -g -o test.x test.cc
    test.xA:ctor[321]
    1
    2
    4
    5
    A:dtor[321]
    Then I uncomment commented line and compiled without -g option:
    CC -o test.x test.ccIn such case program exits unexpectedly without core:
    test.x A:ctor[321]
    1
    compareA:ctor[123]
    false
    A:dtor[123]
    2
    A:dtor[
    If option -g is added, then program works as expected:
    CC -g -o test.x test.cc
    test.xA:ctor[321]
    1
    compareA:ctor[123]
    false
    A:dtor[123]
    2
    4
    5
    A:dtor[321]
    What is wrong?
    PS: I tried all above with latest SunStudio11 and problem is not reproduced.
    Thanks

    It is likely a compiler bug. Thanks for reporting the problem. I filed bug 6570096.
    Dmitry

Maybe you are looking for

  • Reduce Asset Value & give credit to the vendor

    Hi , We have an AUC which has a value of 683,969.70 . Now there is an incorrect APC of 82500.00 done for this asset in last fiscal year . We want to reduce the APC of this asset by 82500.00 this fiscal year and give the credit back to the vendor . Ki

  • How can I install the fonts?

    Hi, I had downloaded the trial CS6 Design & Web Premium, and when I got my license I downloaded 2 additional packages that contained fonts for Illustrator and InDesign. Yet I have no idea what to do with these fonts and I can't find any document on t

  • Problems opening up document

    I am having a problem opening up a document that I had to download.  The problem that it saying I am having is with Adobe Reader; however, it is successfully updated and installed.  Help please, this is for a college class.

  • Issues with unauthorized Adobe products

      An issue is preventing me from donwloading the "Free Grab Photoshop CS2 offered from Google/Adobe. Repairs were made to my computer by an independant IT Man, (friend of a friend) who installed unauthorized software on my computer.  I have tryed num

  • Data fetching comparing dates.

    there are 2 fields in the table Beginging and End date for every employee there r two or more rows. In my selection screen i m selecting month and year.i want to fetch only that row for a employee which comes in date range. for example selection scre