Help us avoid spam *
Want Answer Alerts? *
Asked in Computers & Technology at 12:16 AM on November 25, 2009
Tags: enum
Username
Password
check this link:en.wikipedia.org/wiki/ENUM
Answered by riya thapar , an ibibo Citizen, at 12:55 PM on November 25, 2009
It enumerations for the different operating systemsEnum OsTypesjava.lang.Objecte xtended by java.lang.Enum<OsTypes>exten ded by org.ziptie.common.OsTypesA ll Implemented Interfaces:java.io.Serializa ble, java.lang.Comparable<OsTypes> pu blic enum OsTypesextends java.lang.Enum<OsTypes>...the management and coordination of activities and the sharing of the resources of the computer
named values in groups. If you have a set of values that keep recurring, consider making them into an enum. You will have to deal with the restriction that constant names have to be identifiers, but if that is doable, then enumerations can be very useful.For E.g. enum OFF, ON;The enum defines two integer constants called enumerators and these constants are assigned values by default. The value assigned to OFF
are defined through enumeration declarations An enum type declaration defines a type name for a related group of symbolic constants. The body of an enum type declaration defines zero or more enum members, which are the named constants of the enum type. No two enum members can have the same name. An enum declaration can not contain declarations of methods, properties, events, operators, or types.The associated value
In C, enum signifies a slightly stronger type than in C.For example, in C, one could write:enum Direction UP, DOWN ;Direction d = 1;In C, this would be illegal, only UP or DOWN can be assigned to a the enum was declared as above, declaring variables of type Direction would have to be done through the enum keyword, like this:enum Direction d = UP;In C, the name "Direction" becomes a type
;kernel32" As LongCurrent State EnumerationPrivate Enum enumStateStopped = 0Playing = 1Paused = 2End EnumOur class variablesPrivate strAlias As StringPrivate strFilename As StringPrivate lngLastTick, lngElapsedTime, lngLastPosition As LongPrivate stState As enumStateThis function send the message out to the API.Private Function DoCmdByVal cCmd As String, Optional ByRef ReturnString As String = 0
ENUM or enum may refer to: Telephone Number Mapping, a suite of protocols to unify the telephone system with the Internet In some programming languages, enum is a keyword used for introducing an enumerated type. By extension, "enum" is often used to refer to such a type....ENUM stands for Telephone Number Mapping. Behind this abbreviation hides a great idea: To be reachable anywhere
TMP:template< unsigned char byte > class BITSSETpublic: enum B0 = byte & 0x01 ? 1:0, B1 = byte & 0x02 ? 1:0, B2 = byte & 0x04 ? 1:0, B3 = byte & 0x08 ? 1:0, B4 = byte & 0x10 ? 1:0, B5 = byte & 0x20 ? 1:0, B6 = byte & 0x40 ? 1:0, B7 = byte & 0x80 ? 1:0 ;public: enumRESULT = B0B1B2B3B4B5B6B7;;I have used an enum for the temporary variables as well
questions 2.22 and 17.10. Use any ofdefine TRUE 1define YES 1define FALSE 0define NO 0enum bool false, true;enum bool no, yes;or use raw 1 and 0, as long as you are consistent within one program or project. An enumeration may be preferable if your debugger shows the names of enumeration constants when examining variables.You may also want to use a typedef:typedef int bool;ortypedef char bool;ortypedef enum false
errors. If such intermixing were disallowed without explicit casts, judicious use of enums could catch certain programming errors.Some advantages of enums are that the numeric values are automatically assigned, that a debugger may be able to display the symbolic values when enum variables are examined, and that they obey block scope. A compiler may also generate nonfatal warnings when enums and ints
well, Structures and unions share the following characteristics: Their members can be objects of any type, including other structures and unions or arrays. A member can also consist of a bit field. The only operators valid for use with entire structures and unions are the simple assignment = and siz
At the present time, there is little difference. The C Standard states that enumerations are compatible with integral types....well, At the present time, there is little difference. The C Standardstates that enumerations are compatible with integral types.
leave it for future articles. 4. Enumerations: It can be used to assign names to integer constants. //Program to illustrate Enumerators include<iostream.h> void mainvoid enum type
enum types can be used to set up collections of named integer constants. The keyword enum is short for enumerated. The traditional C way of doing this was something like this: define SPRING 0define SUMMER 1define FALL 2define WINTER 3An alternate approach using enum would be enum SPRING, SUMMER, FALL, WINTER ;