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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T18:59:35+00:00 2026-05-27T18:59:35+00:00

Class<?> baseClass = … Object obj = … Is there a way in GWT

  • 0
Class<?> baseClass = ...
Object obj = ...

Is there a way in GWT to check whether obj‘s type implements/extends baseClass? (that’s client-side code).

  • 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-27T18:59:36+00:00Added an answer on May 27, 2026 at 6:59 pm

    JRE emulation reference says isInstance() is not supported.

    You can use obj instanceOf SomeConcrete.class, and all classes have to be known at compile time. GWT compiler needs to know all the types at compile time (so that it can generate appropriate JavaScript code) so true runtime reflection isn’t possible. I think GWT’s approach to that is deferred binding so that you don’t have to check.

    Here’s a presentation from the 2008 Google IO about this topic:

    Deferred binding is a pluggable compile-time type substitution and code generation mechanism. This unique approach to program modularization provides many of the benefits of Java reflection and dynamic class loading without compromising the GWT compiler’s ability to optimize the heck out of your code.

    Seems like there’s a project for this, gwt-reflection, but I haven’t used it.

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

Sidebar

Related Questions

Suppose that I have the following python base class: class BaseClass(object): def a(): This
public class BaseClass{ public static T Find<T>(object value){ -- db.get<T>(params, value); } } public
Here is my guess, which doesn't work: class BaseClass(object): def foo(self): return 'foo' def
I have abstract class public abstract class BaseClass { public delegate void ContextMenuClickHandler(object sender,
I have a base class with a lot of __init__ arguments: class BaseClass(object): def
class Program { static void Main(string[] args) { baseClass obj = new baseClass(); obj.intF
I have a class (Descendant1) that inherits from a base class (BaseClass). An instance
If I've got three classes like this: class BaseClass(object): def __init__(self, base_arg, base_arg2=None): ...
I have base class BaseClass and derived classes DerivedA , DerivedB , and DerivedC
i have an abstract class BaseClass with a public insert() method: public abstract class

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.