GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Interview Questions  >  J2EE  >  Core Java
Go To First  |  Previous Question  |  Next Question 
 Core Java  |  Question 176 of 502    Print  
How to create own Marker Interface with example

  
Total Answers and Comments: 2 Last Update: November 28, 2005     Asked by: gopi popuri 
  
 Sponsored Links

 
 Best Rated Answer

No best answer available. Please pick the good answer available or submit your answer.
November 28, 2005 08:00:49   #1  
R B        

RE: How to create own Marker Interface with example

Marker interface example-

public interface Serializabale {}

public interface Cloneable {}

Also known as 'Tagging' interface.


 
Is this answer useful? Yes | No
November 28, 2005 08:38:07   #2  
nagarajcse82 Member Since: November 2005   Contribution: 4    

RE: How to create own Marker Interface with example

1.>in general tagged or marker interface is used to just identify the class in real time projects there are so many classes in order to identify which class belongs to which module this tag or marker interface is useful.

2.>

in serialization also if we want to serialize the object first it will internally checks whether the class is implementing java.io.serializable interface by using instanceof operator.

3.>in rmi also every remote class should implement java.rmi.remote interface.

public interface csedept{

}

public class computer implements csedept{

int no;

String name;

}

public class Sample

{

computer c new computer();

if(c instanceof csedept)

{

c.name computer science course ;

}

}


 
Is this answer useful? Yes | No

 Related Questions

Latest Answer : Class c=Class.forName("Student");Student s=(Student)c.newInstance();Another method:Student s1= s.clone(); ...
Read Answers (5) | Asked by : chandu

Latest Answer : we can create object in different ways1.new operator2.class.forName3.newInstance4.object.clone ...
Read Answers (4) | Asked by : chandu

br />1.what is oracle.2.what is major differenece oracle8i and oracle9i.4.tell me some thing ur self.5.please tell me about oops.6.what is single inheritance.7.what is multiple inheritance.8.can java support 
Latest Answer : 8.can java support multiple inheritance.java support multiple inheritance for interfaces not fro classes25.what is difference between procedure and functions.function returns only one value where as procedure returns more than one value ...
Read Answers (11) | Asked by : rajjava

Latest Answer : u can thru batch process ...
Read Answers (2) | Asked by : Beena

Latest Answer : 1.By implementing Runnable interface  2.By Extends Thread class ...
Read Answers (3) | Asked by : dinakar

I want to create two instances of a class ,But when trying for creating third instance it should not allow me to create . what i have to do for making this?
Read Answers (4) | Asked by : chandu

Latest Answer : An interface is a specification of method prototypes. All the methods of interface are public and abstract. They are public because they should be available to third party vendors and they are abstract because their implementation is left for third party ...
Read Answers (11) | Asked by : prakash

I need some more information about interface. For Example there is no any functionality inside the method which is declared in any interface. Then why i want to implement that interface to my class. 2. Statement is an interface. When i say stmt.executeQuery(). I am getting the records in my ResultSet. How it is possible?.. since there is no functionality insid the methods which is declared in Statement Interface. What is happning here?
An idea 

Like Object class is inherited by every class, means every class that you define in java is implicitely extending one class that is Object. Similarly i want to know that which interface is implicitely implemented by every class that we define. let me know as soon as possible. Thanks
I dont know 
Read Answers (2) | Asked by : Hrishikesh

Latest Answer : When we r implementing the some comman methods in the every class at that time we keep that all methods in the one interface. Another way example:- for example for CD Writer soft ware dovelepment all companies(LG,SAMSUNG) follow the method ...
Read Answers (6) | Asked by : Shekhar


 Sponsored Links

 
Related Articles

Service Oriented Java Business Integration Review

Service Oriented Java Business Integration Review Introduction If you ve read through the texts which give you an introduction to SOA or Web Services you will often find them to be quite frustrating and the reason for this is because they spend too much time referencing business processes which are
 

High-Speed Serial Interface (HSSI)

High Speed Serial Interface HSSI HSSI is High Speed Serial Interface was first developed by Cisco systems and the main purpose was to solve high speed requirement issues The main application of HSSI is on the Wide Area Networks and it helps to enhance the data flow speed on these networks It can wor
 

Fiber Distributed Data Interface (FDDI)

Fiber Distributed Data Interface FDDI The Fiber Distributed data interface or the FDDI is a 100 mbps line using the LAN network and is connected through a fiber optic cable The FDDI technology is used where the networks need a high speed bandwidth and need to cover huge distances than the copper wir
 

Java and Client Server Models

Java and Client Server Models The Role of Client Servers on the Web Client server models provide the essential mechanisms for working with the Internet In fact most of the World Wide Web is built according to this paradigm In client server models the web browsers run by millions of users are the cli
 

The Interview Snafu

How to turn someone else’s mistake to your advantage Your dream job is about to become reality. A recruiter gave you the heads up about the perfect position at Humungous Conglomerate, Inc. You went through five interviews as well as a battery of psychological tests mandated by their HR de
 

Winning a Job Interview with a Winning Resume

Does your resume unlock your potential, take your skills to the highest level and win you the interview and the job you want now? The job market today is highly competitive and even if you think you have what it takes to get an interview you won’t get over the line without a polished, prof
 

Using UML with Java

Using UML with Java While Java is not a new language its application for the development of embedded systems is quite new Developers are beginning to take a second look at modeling languages such as UML and many feel it can be a powerful tool in their development arsenal mosgoogle center Introductio
 

Importance of Proper English during Job Interview

Importance of Proper English during Job Interview Your job interview is crucially important and it will determine whether or not you will get the job Depending on the type of job you re going for it is very important for you to use proper English In most cases jobs which offer higher salaries will h
 

Java Technology Trends

Technology Trends Involving Java Java is an object oriented programming language OOP for Web browsers It is organized around data rather than actions and supports polymorphism which allows the same code to be written generically so it can function with different datatypes inheritance which allows on
 

HR Interview - HR Interview Mistakes You Will Want To Avoid

HR Interview Mistakes You Will Want To Avoid The job interview can be a stressful process This is especially true for those who are going after a competitive position Your nonverbal communication combined with the answers you give during the interview will determine if you are hired mosgoogle While
 

About Us -  Privacy Policy -  Terms and Conditions -  Contact -  Ask Question -  Propose Category -  Site Updates 

Copyright © 2005 - 2009 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape