by: Wenjie |
last post by:
Hello,
I have a class B to mediate/isolate between
implementation and their users (like used in
an abstract factory class pattern):
// B.h
class B {
static B* getImpl();
static void...
|
by: Jim West |
last post by:
Both
int a;
std::complex<float> b;
std::complex<float> c = static_cast<float>(a)*b;
and
int a;
std::complex<float> b;
|
by: GianGuz |
last post by:
Everyone knows about the complex and cpu-expensive procedures taken by
dynamic_cast to find the right function call in a virtual classes
hierarchy.
The question I would to rise is when...
|
by: nin234ATIyahoo.com |
last post by:
Hi all
I have a logger class and facing the following issue
enum eErrLvl
{
eLOG_DEBUG_5 = 1,
eLOG_DEBUG_4,
eLOG_DEBUG_3,
eLOG_DEBUG_2,
eLOG_DEBUG_1,
|
by: bonham |
last post by:
i m a beginner in C++. I have some questions:
what is static_cast<unsigned>?
i saw someone use static_cast<unsigned> and static_cast<unsigned char>
together. why?
e.g....
|
by: Dave Rahardja |
last post by:
Is it safe to use static_cast to downcast from a virtual base class?
For example,
class V {};
class A: public virtual V {};
class B: public virtual V {};
class C: public A, public B;
void...
|
by: Rahul |
last post by:
Hi,
I have a
class A : public B {...member functions......data members};
and am doing the following
A *p=new A();
void *p=static_cast<void *>(p);
factory_instance->process(p);
|
by: Bo Peng |
last post by:
Dear C++ experts,
I need to store and retrieve a meta information that can be int or
double. The program would be significantly simpler if I can handle two
types uniformly. Right now, I am using...
|
by: Jim Langston |
last post by:
Is the following well defined?
size_t IntVal = 65537;
unsigned short Length;
if ( IntVal static_cast<unsigned short>( -1 ) )
{
std::cout << "Value too long to fit in a short" << std::endl;...
|
by: Rahul |
last post by:
Hi,
Everywhere I read that static_cast<only work fine for the conversion
which are implicitly allowed by the compiler
hence the following does not work
int *i;
double *d;
d = i; ...
|
by: taylorcarr |
last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|