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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T07:05:13+00:00 2026-05-16T07:05:13+00:00

I always have a question about override custom event. I am not sure why

  • 0

I always have a question about override custom event. I am not sure why or what do to inside override function. I searched google but didn’t get too many feedbacks. I appreciate if someone can light me up. Thanks.

EDIT:

My projects seem work fine even though I use my custom event without override. Anyone could explain it? Thanks.

  • 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-16T07:05:14+00:00Added an answer on May 16, 2026 at 7:05 am

    From the docs:

    When creating your own custom Event
    class, you must override the inherited
    Event.clone() method in order for it
    to duplicate the properties of your
    custom class. If you do not set all
    the properties that you add in your
    event subclass, those properties will
    not have the correct values when
    listeners handle the redispatched
    event.

    So, you can have a problem if you don’t override clone and redispatch an Event. Also, the problem is not only that the custom properties will not be copied. The clone method will be called on the base class, Event. This will return an Event object, not a CustomEvent. If you have a handler that expects a CustomEvent and receives an Event, an error will be thrown and the code in your handler will not run.

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

Sidebar

Related Questions

I have a quick question about the accelerometer in Android devices. Is it always
I have a simple question, but I'm searching for longer time, but I always
I have a question about the examples in this article: http://code.google.com/appengine/articles/transaction_isolation.html Suppose I put
I have some question about lazy evaluation of c++, can I be sure that
I have a question about Subversion. I have always been an end user so
I always get stuck on foreign keys so I have a question about where
just a general question, do you ALWAYS have to handle error? i was just
I am new to Stack Overflow and have a question about JSF 2.0 and
I'm studying about windows and DLL stuffs and I have some question about it.
I have a question about how to add users to AD using powershell, ive

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.