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 4251064
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T04:36:42+00:00 2026-05-21T04:36:42+00:00

I have a custom class that is currently not extending anything (it’s for executing

  • 0

I have a custom class that is currently not extending anything (it’s for executing specific types of queries on a database) but I need it to send an event to its parent class. addEventListener is not defined in it, though.

I notice a lot of the main flash classes extend EventDispatcher, so is that what I should do if there’s no other alternative? Just have any class that will have to communicate with other classes extend EventDispatcher?

  • 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-21T04:36:42+00:00Added an answer on May 21, 2026 at 4:36 am

    There are a couple of things you can do, you are definitely not limited to using events. Events are nice because it decouples code, and allows many objects to act on a single event, without the object that dispatches the event from caring who is listening, or what they are doing. If you want to dispatch events, extend EventDispatcher, or have one as a property of your object. (Some times you may need to define it as a property if you are already extending another class.)

    Alternatively your object can maintain a reference to another object, and explicitly call methods on it. In this case you do not need to extend EventDispatcher, but you must store a reference to all other objects you want to communicate with.

    Both solutions accomplish the same end result, it comes down to situation and/or preference.

    I hope that helps.

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

Sidebar

Related Questions

Currently on a view I have a ImageView and A custom class that draws
I have a custom class that has as an instance variable of a coordinate:
I have a custom class that uses boost mutexes and locks like this (only
I have a custom class that I use to build table strings. I would
I have a custom ButtonUI class that paints the button. Before drawing the text,
I have a custom iterator template class that wraps up a std::list iterator. In
I have created a custom collection class that I am trying to bind to
I have a listbox that displays Shipment Items (custom class) that are formatted using
Here is my custom class that I have that represents a triangle. I'm trying
i'm missing something fundamental here. i have a very simple custom class that draws

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.