• Navigation überspringen
  • Zur Navigation
  • Zum Seitenende
Organisationsmenü öffnen Organisationsmenü schließen
Friedrich-Alexander-Universität Lehrstuhl für Informatik 4 (Systemsoftware)
  • FAUZur zentralen FAU Website
  1. Friedrich-Alexander-Universität
  2. Technische Fakultät
  3. Department Informatik
Suche öffnen
  • English
  • Campo
  • StudOn
  • FAUdir
  • Stellenangebote
  • Lageplan
  • Hilfe im Notfall
  1. Friedrich-Alexander-Universität
  2. Technische Fakultät
  3. Department Informatik
Friedrich-Alexander-Universität Lehrstuhl für Informatik 4 (Systemsoftware)
Menu Menu schließen
  • Lehrstuhl
    • Team
    • Aktuelles
    • Kontakt und Anfahrt
    • Leitbild
    • 50-jähriges Jubiläum
    Portal Lehrstuhl
  • Forschung
    • Forschungsbereiche
      • Betriebssysteme
      • Confidential Computing
      • Eingebettete Systemsoftware
      • Verteilte Systeme
    • Projekte
      • AIMBOS
      • BALu
      • BFT2Chain
      • DOSS
      • Mirador
      • NEON
      • PAVE
      • ResPECT
      • Watwa
    • Projektkampagnen
      • maRE
    • Seminar
      • Systemsoftware
    Portal Forschung
  • Publikationen
  • Lehre
    • Sommersemester 2025
      • Applied Software Architecture
      • Ausgewählte Kapitel der Systemsoftware
      • Betriebssystemtechnik
      • Projekt angewandte Systemsoftwaretechnik
      • System-Level Programming
      • Systemnahe Programmierung in C
      • Systemprogrammierung 1
      • Verteilte Systeme
    • Wintersemester 2024/25
      • Betriebssysteme
      • Middleware – Cloud Computing
      • Systemprogrammierung 2
      • Verlässliche Echtzeitsysteme
      • Virtuelle Maschinen
      • Web-basierte Systeme
    Portal Lehre
  • Examensarbeiten
  1. Startseite
  2. Extern

Extern

Bereichsnavigation: Lehre
  • Betriebssystemtechnik
    • Vorlesung
      • Folien
      • Glossar
    • Übung
      • Aufgaben
      • Dokumentation
        • Blog
          • Entwicklungsumgebung
            • Assembler Crashkurs
              • C++ Crashkurs
                • 🔗 Testrechnerverwaltung
                • Kontakt
              • Evaluation

              Dokumentation

              Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
              Stringbuffer Class Referenceabstract

              The class Stringbuffer composes single characters into a longer text that can be processed on block. More...

              #include <object/stringbuffer.h>

              + Inheritance diagram for Stringbuffer:
              [legend]

              Public Member Functions

              virtual ~Stringbuffer ()
               Destructor (nothing to do here)
               

              Protected Member Functions

               Stringbuffer ()
               Constructor; Marks the buffer as empty.
               
              void put (char c)
               Inserts a character into the buffer. More...
               
              virtual void flush ()=0
               Flush the buffer contents. More...
               

              Protected Attributes

              char buffer [80]
               buffer containing characters that will be printed upon flush()
               
              long unsigned pos
               current position in the buffer
               

              Detailed Description

              The class Stringbuffer composes single characters into a longer text that can be processed on block.

              To make Stringbuffer as versatile as possible, the class does make assumptions about neither the underlying hardware, nor the meaning of "processing". When flush() is called (i.e., either on explicit request or once the buffer is full). To be hardware independent, flush() is to be implemented by the derived classes.

              Hints for Implementation
              Use a buffer of fixed size for caching characters, which should be accessible by derived classes. Keep in mind that the derived implementation of flush() will need to know about numbers of characters in the buffer.
              Notes
              Reason for the existence of this class is that generating longer texts is often implemented by assembly of small fragments (such as single characters or numbers). However, writing such small fragments directly to (for example) screen is quite inefficient (e.g., due to the use of IO ports, syscalls, or locks) and can be improved drastically by delaying the output step until the assembly is finished (or the buffer runs full).

              Member Function Documentation

              void Stringbuffer::put ( char  c)
              protected

              Inserts a character into the buffer.

              Once the buffer is full, a call to flush() will be issued and thereby clearing the buffer.

              Parameters
              cChar to be added
              virtual void Stringbuffer::flush ( )
              protectedpure virtual

              Flush the buffer contents.

              This method is to be defined in derived classes, as only those know how to print characters. flush() is required to reset the position pos.

              Implemented in OutputStream, TextStream, and SerialStream.


              The documentation for this class was generated from the following files:
              • object/stringbuffer.h
              • object/stringbuffer.cc
              Friedrich-Alexander-Universität
              Erlangen-Nürnberg

              Schlossplatz 4
              91054 Erlangen
              • Impressum
              • Datenschutz
              • Barrierefreiheit
              • Facebook
              • RSS Feed
              • Xing
              Nach oben