--%>

File handling modes and corresponding flags

Q. Describe file handling modes and corresponding flags with examples in C++.

Ans. File handling modes specifiers the purpose for which the file is opened. The file mode parameters can take one (or more) of such constants defined in the class ios. Lists the file parameters and their meanings. Opening a file ios : : out mode also opens it is the ios : : trunk mode by default. Both ios : : app and ios : : ate us to the end of the file when it is opened. The distinction between the two parameters is that the ios : : app mode permits us to add data or to modify the existing data anywhere in the file. In both the cases, a file is created by the specifier name, if it does not exist. The parameter can be used only with the file capable of output. The mode can combine two or more parameters using the bitwise OR operator (symbol ||).

 

 

 

 

   Related Questions in Programming Languages

  • Q : How Java client access Corba A Corba

    A Corba remote object exists. How could you get a Java client to access this object?

  • Q : Define Zip file Zip file : It is a file

    Zip file: It is a file employed to store compressed versions of the files. In connection with Java bytecode files, such have mostly been superseded by the Java Archive (abbreviated as JAR) files.

  • Q : Learning File system with operations

    Program 1. Purpose of this assignment is to learn to work with files.Assignment: The file, data.txt, is provided on the class website. Each line of the file consists of a binary operator followed by two operands. Your program wi

  • Q : Define Compiler Compiler : A program

    Compiler: A program that executes a process of compilation on a program written in the high level programming language.

  • Q : Protocol stack of XML Web Services

    Explain the protocol stack of XML Web Services.

  • Q : What is Hash function Hash function : A

    Hash function: A function employed to generate a hash code from the random contents of an object. The classes can override the hash Value method, inherited from the Object class, to state their own hash function.

  • Q : Define the term Multiprogramming system

    Define the term Multiprogramming system: It is an operating system which is able to run multiple programs parallel.

  • Q : Explain the way to back-up active

    Explain the way to back-up active directory.

  • Q : Explain the applications of packing

    Explain the applications of packing life cycle.

  • Q : "Const" qualifier for pointers and

    In C++ an arguments to a function can be declared as constant as shown below:

    Discover Q & A

    Leading Solution Library
    Avail More Than 1449112 Solved problems, classrooms assignments, textbook's solutions, for quick Downloads
    No hassle, Instant Access
    Start Discovering

    18,76,764

    1952405
    Asked

    3,689

    Active Tutors

    1449112

    Questions
    Answered

    Start Excelling in your courses, Ask an Expert and get answers for your homework and assignments!!

    Submit Assignment

    ©TutorsGlobe All rights reserved 2022-2023.