পৃষ্ঠাসমূহ

Search Your Article

CS

 

Welcome to GoogleDG – your one-stop destination for free learning resources, guides, and digital tools.

At GoogleDG, we believe that knowledge should be accessible to everyone. Our mission is to provide readers with valuable ebooks, tutorials, and tech-related content that makes learning easier, faster, and more enjoyable.

What We Offer:

  • 📘 Free & Helpful Ebooks – covering education, technology, self-development, and more.

  • 💻 Step-by-Step Tutorials – practical guides on digital tools, apps, and software.

  • 🌐 Tech Updates & Tips – simplified information to keep you informed in the fast-changing digital world.

  • 🎯 Learning Support – resources designed to support students, professionals, and lifelong learners.

    Latest world News 

     

Our Vision

To create a digital knowledge hub where anyone, from beginners to advanced learners, can find trustworthy resources and grow their skills.

Why Choose Us?

✔ Simple explanations of complex topics
✔ 100% free access to resources
✔ Regularly updated content
✔ A community that values knowledge sharing

We are continuously working to expand our content library and provide readers with the most useful and relevant digital learning materials.

📩 If you’d like to connect, share feedback, or suggest topics, feel free to reach us through the Contact page.

Pageviews

Saturday, January 28, 2017

C++ Library -

Introduction

This data type represents the file stream generally, and has the capabilities of both ofstream and ifstream which means it can create files, write information to files, and read information from files.

Definition

Below is definition of std::fstream.
template<
   class CharT, 
   class Traits = std::char_traits<CharT>> 
class basic_fstream : public std::basic_iostream<CharT, Traits>

Parameters

  • charT − Aliased as member char_type.
  • traits − Aliased as member traits_type.

Member types

Following member types can be used as parameters or return type by member functions.
S.N. Member types Definition
1 char Character Type
2 char_traits<char> traits_type
3 int const value_type
4 int int_type
5 streampos pos_type
6 streamoff off_type

Functions from <fstream>

Below is list of all methods from <fstream>

Member functions

S.N. Method & description
1 fstream::close Closes the file currently associated with the object, disassociating it from the stream.
2 fstream::is_open Returns whether the stream is currently associated to a file.
3 fstream::open Opens the file identified by argument filename, associating it with the stream object.
4 fstream::operator= Returns a constant iterator which points to the start of the array.
5 fstream::rdbuf Returns a pointer to the internal filebuf object.
6 fstream::swap Exchanges all internal data between x and *this.

Non-member overloaded functions

S.N. Method & description
1 swap-free Exchanges the values of the fstream objects x and y.

No comments:

Post a Comment