C ++ standard API

I am a student and new to C ++. I am looking for a standard C ++ API as comprehensive as the Java API. So far I have used cplusplus.com and cppreference.com .

Please any help would be greatly appreciated.

+5
source share
6 answers

C ++ and Java have very different standard libraries because they make very different assumptions about what they will be used for.

Java assumes that applications or applets will be launched on a host with a fully functional OS with a certain way to perform most normal actions.

It has a lot of content, for example, in java, the result is an application or applet. C ++ does not make this assumption, because C ++ can be used to build kernel cores and drivers for cores, it can be used to program real-time applications with a full stack on microcontrollers or processing units in supercomputers.

C ++ can be used to implement the operating system itself on which it will run.

For these reasons, the standard library implies almost nothing that it will be available, and therefore the standard library does not make any dependencies on these functions.

The only exception is with files and streaming, because almost any operating system, such as the stack, has something similar to a file stream, if it even has something like files.

If you need a richer set of OS Specific api, you need to look at something non-standard. A great choice is the foundation of Qt, which provides many tools similar to those found in Java libraries, is cross-platform and works well with native C ++ idioms.

+7
source

C ++ has a standard library.

You can try reading the C ++ Standard Library: Tutorial and Reference . Although I do not own it myself, it is on our list of books (which I recommend you check), so it should not be bad.

Note. C ++ is not Java, so libraries do not necessarily have the same functionality. Another resource you'll want to take a look at is Boost , which serves as a source for well-written C ++ libraries for things that aren't in the standard library.

+4
source

The GNU C ++ Standard Library documentation is the one I most often relate to.

+1
source

Java is a virtual machine language and as such is trying to have a comprehensive api to provide a platform-independent method for drawing / twisting files / everything. In the guts of the JRE, they take these common inputs and use them to do specific things on the platform. In C ++, you do this work. Many C ++ libraries are platform-specific, see MFC, ATL, or code written for XWindows, it is your task to decide how you want to implement this function and see if it is a platform-specific function or can be executed independently from the platform.

If you write on windows or unix, I can assure you that the OS API is very complete and will allow you to do what you have ever tried to accomplish. Also consider cross platfom libraries such as lib qt.

+1
source

The Java standard library is designed to provide ready-to-use functionality, and the C ++ standard library is designed to provide building blocks that are not defined by the main language. The Boost library has basically the same orientation as the standard library (with some exceptions, for example, image processing). I think the closest thing to something like a standard Java library is the Poco library.

However, when I tried in the Poco library, I found that it was too C-oriented for my taste.

That is, it is not "modern." You get this impression right away, without even looking at the API, because online documents use frames from 1990. :-) However, it can satisfy your needs.

+1
source

If you mean the standard c ++ library, I would look at www.cplusplus.com . It covers current standards. After reading this, you can try to look at the increase .
There are a number of changes in the upcoming c ++ 0x standard. Wikipedia has information on a number of them, like fooobar.com/questions/78837 / ....

Book number one, IMO, for c ++ is Scott Meyers' Effective c ++ .

0
source

Source: https://habr.com/ru/post/900871/


All Articles