C++ class design


 
Thread Tools Search this Thread
Top Forums Programming C++ class design
# 1  
Old 11-21-2006
C++ class design

Can anybody tell me what is the best website or books to read for getting good knowledge in doing C++ class design. Please leave cplusplus.com or bjorne stroustrup. Other than these is there any website or book. Please do tell me
Login or Register to Ask a Question

Previous Thread | Next Thread

8 More Discussions You Might Find Interesting

1. Programming

C++ : Base class member function not accessible from derived class

Hello All, I am a learner in C++. I was testing my inheritance knowledge with following piece of code. #include <iostream> using namespace std; class base { public : void display() { cout << "In base display()" << endl; } void display(int k) {... (2 Replies)
Discussion started by: anand.shah
2 Replies

2. Programming

Size of Derived class, upon virtual base class inheritance

I have the two class definition as follows. class A { public: int a; }; class B : virtual public A{ }; The size of class A is shown as 4, and size of class B is shown as 16. Why is this effect ?. (2 Replies)
Discussion started by: techmonk
2 Replies

3. Programming

C++ string class design and implementation

Hi, I am designing the look-alike C++ string class: #include <iostream> #include <cstring> #include <exception> #include <new> #define ALLOC(N) (char*) new char #define DELETE(P) delete ((char*)(P)) class String { public: // conversions: to C-like type char operator const... (2 Replies)
Discussion started by: royalibrahim
2 Replies

4. UNIX for Advanced & Expert Users

Get pointer for existing device class (struct class) in Linux kernel module

Hi all! I am trying to register a device in an existing device class, but I am having trouble getting the pointer to an existing class. I can create a class in a module, get the pointer to it and then use it to register the device with: *cl = class_create(THIS_MODULE, className);... (0 Replies)
Discussion started by: hdaniel@ualg.pt
0 Replies

5. Programming

static use for class inside the same class c++

Hi, I believe the next code is wrong: class Egg { Egg e; int i; Egg(int ii=0) : i(ii) {} }; because you would end up with an endless definition (memory allocation) of Egg objects, thus int i. Ok, so God Eckel proposes for a singleton: class Egg { static Egg e; int... (5 Replies)
Discussion started by: xavipoes
5 Replies

6. Programming

C++ class definition with a member of the same class

Hi, i have a question about C++. Is it possible to declare a class with a member ot the same class? For example, a linked list or i want to convert this C code to C++ class (Elemento) typedef struct elemento { char name; char value; List<struct elemento> ltElementos; ... (7 Replies)
Discussion started by: pogdorica
7 Replies

7. UNIX for Dummies Questions & Answers

car class (not school class)

im just trying to have some fun and kill some time writing a c++ program that has a person type in a car make and model then gives them a year and a price. or something like that. i always have problems getting it goin but once the ball is rolling im usually pretty good. anyone wanna help me out? ... (1 Reply)
Discussion started by: rickym2626
1 Replies

8. Shell Programming and Scripting

I want to design a program

i want to make a shell program. This program i give a current day and the result is to appear the celebrity and birthday(birthday and celebration is 2 txt files). In addition this procedure must do for a space day in future or past depend on user choice. Finally the program can run and as... (2 Replies)
Discussion started by: mytilini boy
2 Replies
Login or Register to Ask a Question
Crypt::Random::Source::Base(3pm)			User Contributed Perl Documentation			  Crypt::Random::Source::Base(3pm)

NAME
Crypt::Random::Source::Base - Abstract base class for Crypt::Random::Source classes SYNOPSIS
use Moose; extends qw(Crypt::Random::Source::Base); DESCRIPTION
This is an abstract base class. In the future it will be a role. METHODS
get $n, %args Gets $n random bytes and returns them as a string. This method may produce fatal errors if the source was unable to provide enough data. read $buf, $n, [ $off ] This method is cannibalized from IO::Scalar. It provides an IO::Handle work-alike. Note that subclasses override this to operate on a real handle directly if available. seed @stuff On supporting sources this method will add @stuff, whatever it may be, to the random seed. Some sources may not support this, so be careful. available This is a class method, such that when it returns true calling "new" without arguments on the class should provide a working source of random data. This is use by Crypt::Random::Source::Factory. rank This is a class method, with some futz value for a ranking, to help known good sources be tried before known bad (slower, less available) sources. get_data %Params Provided for compatibility with Crypt::Random AUTHOR
Yuval Kogman <nothingmuch@woobling.org> COPYRIGHT AND LICENSE
This software is copyright (c) 2011 by Yuval Kogman. This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. perl v5.14.2 2011-01-05 Crypt::Random::Source::Base(3pm)