logging design question

Discussion in 'C++' started by Angus, Nov 29, 2009.

  1. Angus

    Angus Guest

    Hello

    I am building a C++ wrapper for a C API. So for example there is a
    Widget object which encapsulates a Widget (obviously not called that).

    There can be all sorts of reasons why getting/working with the widget
    fails and I am wondering about logging the errors.

    Should I:

    A) have no logging in these classes and simply return error codes?
    B have no logging and just raise an exception?
    C) specify a logging path in constructor for object and log to there?

    Angus
     
    Angus, Nov 29, 2009
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Stefan Siegl
    Replies:
    0
    Views:
    975
    Stefan Siegl
    Aug 27, 2003
  2. janne
    Replies:
    0
    Views:
    9,579
    janne
    Sep 10, 2004
  3. Christoph Haas
    Replies:
    0
    Views:
    472
    Christoph Haas
    Jun 12, 2006
  4. Christoph Haas
    Replies:
    1
    Views:
    476
    Vinay Sajip
    Jun 14, 2006
  5. johnny
    Replies:
    1
    Views:
    665
    Dennis Lee Bieber
    Dec 12, 2006
Loading...

Share This Page