Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6336637
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T19:05:45+00:00 2026-05-24T19:05:45+00:00

I am having the following problem: I obtain an object from an external component

  • 0

I am having the following problem:

I obtain an object from an external component and what I’d like to do is override several of the object’s functions in order to change parts of its behavior.

I tried doing this via a decorator by inheriting from the original object’s class and storing the original object as a member variable, but then I would have to override all the functions in that object.

I also don’t have access to most of the object’s internal data, so I cannot just clone it into my derived object’s base class.

So bottom line is: is there anyway to override a couple of an already instantiated object’s functions while retaining the data and not having to override the entire object functionality?

Thanks,

PM

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T19:05:45+00:00Added an answer on May 24, 2026 at 7:05 pm

    The short answer is, No.

    The longer answer is to write a wrapper around it and yes that means implementing all the methods. YOu can do this via composition.

    .Net isn’t a dynamic language although it has some dynamic feature but I don’t think you component will be dynamic.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm having the following problem. Imagine my mySQL table looks like this: id range
am having the following problem: In my app I am creating a temporary object,
I'm having the following problem: cannot convert from 'MyProject.DataLayerServiceRef.MyDTO' to 'WCFService.MyDTO' when i'm trying
I'm having following problem. I should convert a control to a certain type, this
I'm having the following problem. I created a application context file for spring.net. The
I'm having the following problem and wondered whether anyone could see why this is
I have been having the following problem, i think it's probably due to the
I'm having the following problem using the Visual Studio 2010 Team System Beta 1:
I've been having the following problem with my GoDaddy's server. I am using JSPs
I'm having the following problem: When I got two labels into each other: <Label

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.