CoolInterview.com - World's Largest Collection of Interview Questions & Answers, FAQs, queries, sample papers, exam papers, dumps, what, why, how, where, when questions
Our Services
Get 9,000 Interview Questions & Answers in an eBook.




Get it now !!
Send your Resume to 6000 Companies

Search Interview Questions

Question: What is cts and cls?

Answer: =>cls stands for common language specification where as
cts stands for common type system.
=>CLS : cls is a standard for .net . cls is small set of specification to make all languages as a .net compliant languages. cls make a use of cts and clr. if my languages (c#,vb.net,j#,vc++) wants to be compliant language it has to follow cls standard.

=>CTS : Common Type System is also a standard like cls. If two languages (c# or vb.net or j# or vc++) wants to communicate with eachother, they have to convert into some common type (i.e in clr common language runtime). In c# we use int which is converted to Int32 of CLR to communicate with vb.net which uses Integer or vice versa



Category DotNet Interview Questions & Answers - Exam Mode / Learning Mode
Rating (3.6) By 86 users
Added on 9/9/2013
Views 1111
Rate it!
Question: What is cts and cls?

Answer:

=>cls stands for common language specification where as
cts stands for common type system.
=>CLS : cls is a standard for .net . cls is small set of specification to make all languages as a .net compliant languages. cls make a use of cts and clr. if my languages (c#,vb.net,j#,vc++) wants to be compliant language it has to follow cls standard.

=>CTS : Common Type System is also a standard like cls. If two languages (c# or vb.net or j# or vc++) wants to communicate with eachother, they have to convert into some common type (i.e in clr common language runtime). In c# we use int which is converted to Int32 of CLR to communicate with vb.net which uses Integer or vice versa
Source: CoolInterview.com

Answered by: Saurin | Date: 9/12/2008 | Contact Saurin Contact Saurin

CLS: It Sand For Common Language Specification Which has to follow All Language. All DataType which follows cls specification are Language Interoperability.Unit is non cls part of data type.cls is called as SuperSet.
CTS: It Stand For Common Type System Which provides universe data type available in dotnet.
Unit is part of cts.it is also called as Subset. Source: CoolInterview.com

Answered by: Gajanan Shinde | Date: 10/23/2008 | Contact Gajanan Shinde Contact Gajanan Shinde

Common Language Specification is a set of constructs and constraints that serves as a guide for library writers and compiler writers. The Common Language Specification is subset of the Common Type System(CTS).

The Common Type System defines how types are declared, used, and managed in the runtime, and is also an important part of the runtime's support for cross-language integration. Source: CoolInterview.com

Answered by: vishnu | Date: 4/27/2009 | Contact vishnu Contact vishnu

CLS means common language specification which says that all .net languages(c# or vb.net or j#.net....) when compiled has to generate the same type of IL code when targeting the .net framework.
CTS means common type system which says that all the data types present in various .net languages should adopt the same data structure.ie.,while converting vb.net code to c#.net,integer of vb.net is shown as int32 to c# by Intermediate language(IL). Source: CoolInterview.com

Answered by: ram | Date: 9/12/2009 | Contact ram Contact ram

cls:comman language specification we abbrivate,now ls: language specificaion means list of syntactical rules to build one application or progarm or language,and here these ruls comman to all dotnet compatible languages.
ex: c#(dotnet comatible lang)
perl.net(same)
(why comman rules?)=improving conversion capabulity to an applicaion or program or language by internolly only.
cts:by using any lang,if we want declare variable(i) as 10,needs different structures as per the lang rules& structure,but here 1 common format internolly understood by .net f/w is cts available in diff modes...int16,int32 Source: CoolInterview.com

Answered by: kurmanath | Date: 6/16/2010 | Contact kurmanath Contact kurmanath

cls is a standard for .net . cls is small set of specification to make all languages as a .net compliant languages.
All DataType which follows cls specification are Language Interoperability.Unit is non cls part of data type.cls is called as SuperSet.
Source: CoolInterview.com

Answered by: Arvind Rathour | Date: 8/3/2010 | Contact Arvind Rathour Contact Arvind Rathour

CTS and CLS are parts of .NET CLR and are responsible for type safety with in the code. Both allow cross language communication and type safety. In this article I would like to expose the relationship between these two.

CTS stands for Common Type System. It defines the rules which Common Language Runtime follows when declaring, using, and managing types. The common type system performs the following functions:

It enables cross-language integration, type safety, and high-performance code execution.

It provides an object-oriented model for implementation of many programming languages.

It defines rules that every language must follow which runs under .NET framework. It ensures that objects written in different .NET Languages like C#, VB.NET, F# etc. can interact with each other.


CLS

CLS stands for Common Language Specification and it is a subset of CTS. It defines a set of rules and restrictions that every language must follow which runs under .NET framework. The languages which follows these set of rules are said to be CLS Compliant. In simple words, CLS enables cross-language integration.

For example, one rule is that you cannot use multiple inheritance within .NET Framework. As you know C++ supports multiple inheritance but; when you will try to use that C++ code within C#, it is not possible because C# doesn?t supports multiple inheritance.

One another rule is that you cannot have members with same name with case difference only i.e. you cannot have add() and Add() methods. This easily works in C# because it is case-sensitive but when you will try to use that C# code in VB.NET, it is not possible because VB.NET is not case-sensitive. Source: CoolInterview.com

Answered by: Shankar kumar | Date: 9/9/2010 | Contact Shankar kumar Contact Shankar kumar


If you have the better answer, then send it to us. We will display your answer after the approval

Rules to Post Answers in CoolInterview.com:-

  • There should not be any Spelling Mistakes.
  • There should not be any Gramatical Errors.
  • Answers must not contain any bad words.
  • Answers should not be the repeat of same answer, already approved.
  • Answer should be complete in itself.

Post your answer here

Inform me about updated answers to this question.
Related Questions
View Answer
What is the purpose of DOTNET?
View Answer
Give the detail procedure of how to add different controls at runtime in VB and dot Net. The controls should be added as per the customers requirement at the customers place without intervention of the programmer. Similarly how to remove these controls which are generated by the customer at runtime?
View Answer
With respect to security ,which one is the better choice?.Net or J2EE? Explain.

View Answer
What is the difference between the C#.NET and VB.NET?

View Answer
Can implement same method name in both base class And derived class with different action?

View Answer
Can i change private assembly to shared assembly?How?

View Answer
How u can create XML file?

View Answer
How can I read .doc document in ASP.Net?

View Answer
Can we run .NET in unix plateform?

View Answer
In .NET Compact Framework, can I free memory explicitly without waiting for garbage collector to free the memory?

View Answer
what i do for load testing in . net application .



View Answer
How many types of assemblies are there , wat are they?

View Answer
What's ArrayList in .Net (VB.Net or C#)
What's the advantageous using ArrayList.




View Answer
How to clear a datagrid on a button click?

View Answer
How will you make .NET programs work in Linux ?

View Answer
Given a server with 4 cpu's, and no databases write a pseudocode to search for the word camera in 100,000 html documents.



View Answer
With respect to security ,which one is the better choice ,.Net or J2EE? Explain.........

View Answer
What Is The Difference Between ViewState and SessionState

View Answer
How different are interface and abstract class in .Net?

View Answer
What is the difference between proc. sent BY VAL and By Ref?
View Answer

Please Note: We keep on updating better answers to this site. In case you are looking for Jobs, Pls Click Here Vyoms.com - Best Freshers & Experienced Jobs Website.

View All DotNet Interview Questions & Answers - Exam Mode / Learning Mode




India News Network
Latest 20 Questions
An offer which is open for acceptance over a period of time is: (a) Cross Offer (b) Counter Offer (c) Standing Offer (d) Implied Offer
Specific offer can be communicated to__________ (a) All the parties of contract (b) General public in universe (c) Specific person (d) None of the above
_________ amounts to rejection of the original offer. (a) Cross offer (b) Special offer (c) Standing offer (d) Counter offer
A advertises to sell his old car by advertising in a newspaper. This offer is caleed: (a) General Offer (b) Special Offer (c) Continuing Offer (d) None of the above
In case a counter offer is made, the original offer stands: (a) Rejected (b) Accepted automatically (c) Accepted subject to certain modifications and variations (d) None of the above
In case of unenforceable contract having some technical defect, parties (a) Can sue upon it (b) Cannot sue upon it (c) Should consider it to be illegal (d) None of the above
If entire specified goods is perished before entering into contract of sale, the contract is (a) Valid (b) Void (c) Voidable (d) Cancelled
______________ contracts are also caled contracts with executed consideration. (a) Unilateral (b) Completed (c) Bilateral (d) Executory
A offers B to supply books @ Rs 100 each but B accepts the same with condition of 10% discount. This is a case of (a) Counter Offer (b) Cross Offer (c) Specific Offer (d) General Offer
_____________ is a game of chance. (a) Conditional Contract (b) Contingent Contract (c) Wagering Contract (d) Quasi Contract
There is no binding contract in case of _______ as one's offer cannot be constructed as acceptance (a) Cross Offer (b) Standing Offer (c) Counter Offer (d) Special Offer
An offer is made with an intention to have negotiation from other party. This type of offer is: (a) Invitation to offer (b) Valid offer (c) Voidable (d) None of the above
When an offer is made to the world at large, it is ____________ offer. (a) Counter (b) Special (c) General (d) None of the above
Implied contract even if not in writing or express words is perfectly _______________ if all the conditions are satisfied:- (a) Void (b) Voidable (c) Valid (d) Illegal
A specific offer can be accepted by ___________. (a) Any person (b) Any friend to offeror (c) The person to whom it is made (d) Any friend of offeree
An agreement toput a fire on a person's car is a ______: (a) Legal (b) Voidable (c) Valid (d) Illegal
"Holiday Packages" announced as an advertisement are an example of _________: (a) Offer (b) Counter Offer (c) Invitation to Offer (d) None of the above
A match fixing contract between a player and a broker is a: (a) Valid Contract (b) Unenforceable Contract (c) Void Contract (d) Illegal Contract
When a bookseller sells a book on cash payment then it is called as ___________: (a) Unilateral Contract (b) Bilateral Contract (c) Executed Contract (d) Executory Contract
____________ agreements are created by situation: (a) Written (b) Oral (c) Void (d) Implied
Cache = 0.015625 Seconds