diff --git a/src/documentation/haiku_book/support/DataIO.xml b/src/documentation/haiku_book/support/DataIO.xml new file mode 100644 index 0000000000..8f01af6a28 --- /dev/null +++ b/src/documentation/haiku_book/support/DataIO.xml @@ -0,0 +1,53 @@ + + + + BDataIO + + + Derived from: none + Declared in: os/support/DataIO.h + Library: libbe.so + + + BDataIO provides a base interface for reading and writing data. + + Constructors and Destructors + + BDataIO() + + + BDataIO + + + + + ~BDataIO() + + + virtual~BDataIO + + + + Member Functions + + Read() + + + virtualssize_tRead + void *buffer + size_tsize + = 0 + + + + + Write() + + + virtualssize_tWrite + constvoid *buffer + size_tsize + = 0 + + + diff --git a/src/documentation/haiku_book/support/MallocIO.xml b/src/documentation/haiku_book/support/MallocIO.xml new file mode 100644 index 0000000000..b04d72c324 --- /dev/null +++ b/src/documentation/haiku_book/support/MallocIO.xml @@ -0,0 +1,105 @@ + + + + BMallocIO + + + Derived from:BPositionIO + Declared in: os/support/DataIO.h + Library: libbe.so + + + BMallocIO provides an interface for reading, writing and seeking in a buffer that it maintains itself. + + Constructors and Destructors + + BMallocIO() + + + BMallocIO + + + + + ~BMallocIO() + + + virtual~BMallocIO + + + + Member functions + + Buffer() + + + const void *Bufferconst + + + + + BufferLength() + + + size_tBufferLength()const + + + + + Position() + + + virtualoff_tPositionconst + + + + + ReadAt() + + + virtualssize_tReadAt + off_tposition + void *buffer + size_tsize + + + + + Seek() + + + virtualoff_tSeek + off_tposition + uint32seekMode + + + + + SetBlockSize() + + + SetBlockSize + size_tblockSize + + + + + SetSize() + + + virtualstatus_tSetSize + off_tsize + + + + + WriteAt() + + + virtualssize_tWriteAt + off_tposition + constvoid *buffer + size_tsize + + + \ No newline at end of file diff --git a/src/documentation/haiku_book/support/MemoryIO.xml b/src/documentation/haiku_book/support/MemoryIO.xml new file mode 100644 index 0000000000..c7860d1782 --- /dev/null +++ b/src/documentation/haiku_book/support/MemoryIO.xml @@ -0,0 +1,88 @@ + + + + BMemoryIO + + + Derived from:BPositionIO + Declared in: os/support/DataIO.h + Library: libbe.so + + + BMemoryIO implements reading, writing and seeking in a data buffer. + + Constructors and Destructors + + BMemoryIO() + + + BMemoryIO + void *data + size_tlength + + + + BMemoryIO + constvoid *data + size_tlength + + + + + ~BMemoryIO() + + + virtual~BMemoryIO + + + + Member functions + + Position() + + + virtualoff_tPositionconst + + + + + ReadAt() + + + virtualssize_tReadAt + off_tposition + void *buffer + size_tsize + + + + + Seek() + + + virtualoff_tSeek + off_tposition + uint32seekMode + + + + + SetSize() + + + virtualstatus_tSetSize + off_tsize + + + + + WriteAt() + + + virtualssize_tWriteAt + off_tposition + constvoid *buffer + size_tsize + + + diff --git a/src/documentation/haiku_book/support/PositionIO.xml b/src/documentation/haiku_book/support/PositionIO.xml new file mode 100644 index 0000000000..0f7cf94adf --- /dev/null +++ b/src/documentation/haiku_book/support/PositionIO.xml @@ -0,0 +1,112 @@ + + + + BPositionIO + + + Derived from:BDataIO + Declared in: os/support/DataIO.h + Library: libbe.so + + + BPositionIO provides an interface for reading, writing and seeking within data. + + Constructors and Destructors + + BPositionIO() + + + BPositionIO + + + + + ~BPositionIO() + + + virtual~BPositionIO + + + + Member functions + + GetSize() + + + virtualstatus_tGetSize + off_t *size + + + + + Position() + + + virtualoff_tPositionconst= 0 + + + + + Read() + + + virtualssize_tRead + void *buffer + size_tsize + + + + + ReadAt() + + + virtualssize_tReadAt + off_tposition + void *buffer + size_tsize + = 0 + + + + + Seek() + + + virtualoff_tSeek + off_tposition + uint32seekMode + = 0 + + + + + SetSize() + + + virtualstatus_tSetSize + off_tsize + + + + + Write() + + + virtualssize_tWrite + constvoid *buffer + size_tsize + + + + + WriteAt() + + + virtualssize_tWriteAt + off_tposition + constvoid *buffer + size_tsize + = 0 + + + diff --git a/src/documentation/haiku_book/support/StopWatch.xml b/src/documentation/haiku_book/support/StopWatch.xml new file mode 100644 index 0000000000..2259748b9c --- /dev/null +++ b/src/documentation/haiku_book/support/StopWatch.xml @@ -0,0 +1,151 @@ + + + + BStopWatch + + + Derived from: none + Declared in: os/support/StopWatch.h + Library: libbe.so + + + BStopWatch is a timer class. + + + This class provides method to time events. The interface is designed to behave like a + physical stopwatch. It is especially useful for debugging certain parts of your code, since + it can behave like a 'cheap' profiler. + + + Constructors and Destructors + + BStopWatch() + + + BStopWatch + constchar *name + boolsilentfalse + + + + The constructor creates a clean BStopWatch object. This object + can be given a name. As soon as the object is created, the time + will start ticking away. This class is designed to be usuable as a primitive profiling tool. + If you are profiling your code with this class, pass true as the + silent parameter. Whenever the object is destroyed, information on + the elapsed time will be streamed to standard output. + + + + + ~BStopWatch() + + + virtual~BStopWatch + + + + Destroys the object. If the object was constructed with the parameter + silent set t to false, this destructor will print + information on the elapsed time to standard output. + + + + Member Functions + + ElapsedTime() + + + bigtime_tElapsedTimeconst + + + + This method returns the elapsed time in microseconds since the object was created. If + the object is suspended, the time until the suspend will be returned. + + + + See also: Suspend(). + + + + + Lap + + + bigtime_tLap + + + + This method sets a lap. With the current implementation you are unable to actually + retrieve the timings of the laps. This is only printed to the standard output when the + object is destroyed. Thus making this tool only usuable for use when doing some + profiling. + + + + Please note that the current implementation is limited to 10 laps. The value returned + is the time that has passed since the timer was started (and not the time that has + passed since the last lap). Any lap call beyond the 10th lap will overwrite the last + value. Note that if the timer is suspended, nothing happens and the method will return + 0. + + + + + Name() + + + const char *Nameconst + + + + Returns the name that was given when the object was constructed. + + + + + Reset() + + + Reset + + + + Resets the object: it clears the start time, it clears the stored laps and it restarts + the timer. + + + + + Resume() + + + Resume + + + + Resumes the timer when it is in a suspended state. + + + + See Also: Suspend(). + + + + + Suspend() + + + Suspend + + + + Suspends the timer. + + + + See Also: Resume(). + + + diff --git a/src/documentation/haiku_book/support/String.xml b/src/documentation/haiku_book/support/String.xml index 5d7ea8c65f..c1aea79fc0 100644 --- a/src/documentation/haiku_book/support/String.xml +++ b/src/documentation/haiku_book/support/String.xml @@ -1,517 +1,663 @@ - - - - BString - - - Derived from: none - Declared in: os/support/String.h - Library: libbe.so - - - BString implements a high level string object. - - Constructors and Destructors - - BString() - - - BString - - - - BString - constchar *string - - - - BString - constBString &string - - - - BString - constchar *string - int32maxLength - - - - - ~BString() - - - ~BString() - - - - Member Functions - - Adopt() - - - BString &Adopt - BString &from - - - - BString &Adopt - BString &from - int32length - - - - - Append() - - - BString &Append - constBString &string - - - - BString &Append - const char *string - - - - BString &Append - constBString &string - int32length - - - - BString &Append - constchar *string - int32length - - - - BString &Append - charstring - int32count - - - - - Compare() - - - intCompare - constBString &string - const - - - - intCompare - constchar *string - const - - - - intCompare - constBString &string - int32n - const - - - - intCompare - constchar *string - int32n - const - - - - - CopyInto() - - - BString &CopyInto - BString &into - int32fromOffset - int32length - - - - CopyInto - char *into - int32fromOffset - int32length - - - - - CountChars() - - - int32CountCharsconst - - - - - ICompare() - - - intICompare - constBString &string - const - - - - intICompare - constchar *string - const - - - - intICompare - constBString &string - int32n - const - - - - intICompare - constchar *string - int32n - const - - - - - Insert() - - - BString &Insert - constchar *string - int32pos - - - - BString &Insert - constchar *string - int32length - int32pos - - - - BString &Insert - constchar *string - int32fromOffset - int32length - int32pos - - - - BString &Insert - constBString &string - int32pos - - - - BString &Insert - constBString &string - int32length - int32pos - - - - BString &Insert - constBString &string - int32fromOffSet - int32length - int32pos - - - - BString &Inser - charstring - int32count - int32pos - - - - - Length() - - - int32Lengthconst - - - - - MoveInto() - - - BString &MoveInto - BString &into - int32from - int32length - - - - MoveInto - char *into - int32from - int32length - - - - - Prepend() - - - BString &Prepend - constBString &string - - - - BString &Prepend - constchar *string - - - - BString &Prepend - constBString &string - int32length - - - - BString &Prepend - constchar *string - int32length - - - - BString &Prepend - charstring - int32count - - - - - Remove() - - - BString &Remove - int32from - int32length - - - - - RemoveFirst() - - - BString &RemoveFirst - constBString &string - - - - BString &RemoveFirst - constchar *string - - - - - RemoveLast() - - - BString &RemoveLast - constBString &string - - - - BString &RemoveLast - constchar *string - - - - - RemoveAll - - - BString &RemoveAll - constBString &string - - - - BString &RemoveAll - constchar *string - - - - - RemoveSet - - - BString &RemoveSet - constchar *setOfCharsToRemove - - - - - SetTo - - - BString &SetTo - constchar *string - - - - BString &SetTo - constchar *string - int32length - - - - BString &SetTo - constBString &from - - - - BString &SetTo - constBString &from - int32length - - - - BString &SetTo - charstring - int32count - - - - - String() - - - const char *String const - - - - - Truncate() - - - BString &Truncate - int32newLength - boollazytrue - - - - Operators - - = (assignment) - - - BString &operator= - constBString &string - - - - BString &operator= - constchar *string - - - - BString &operator= - charstring - - - - - += (append) - - - BString &operator+= - constBString &string - - - - BString &operator+= - constchar *string - - - - BString &operator+= - constcharcharacter - - - - - <, <=, ==, >, >=, != (comparison) - - - BString &operator< - constBString &string - const - - - - BString &operator< - constchar *string - const - - - - BString &operator<= - constBString &string - const - - - - BString &operator<= - constchar *string - const - - - - BString &operator== - constBString &string - const - - - - BString &operator== - constchar *string - const - - - - BString &operator>= - constBString &string - const - - - - BString &operator>= - constchar *string - const - - - - BString &operator> - constBString &string - const - - - - BString &operator> - constchar *string - const - - - - BString &operator!= - constBString &string - const - - - - BString &operator!= - constchar *string - const - - - + + + + BString + + + Derived from: none + Declared in: os/support/String.h + Library: libbe.so + + + BString implements a high level string object. + + Constructors and Destructors + + BString() + + + BString + + + + BString + constchar *string + + + + BString + constBString &string + + + + BString + constchar *string + int32maxLength + + + + + ~BString() + + + ~BString() + + + + Member Functions + + Adopt() + + + BString &Adopt + BString &from + + + + BString &Adopt + BString &from + int32length + + + + + Append() + + + BString &Append + constBString &string + + + + BString &Append + const char *string + + + + BString &Append + constBString &string + int32length + + + + BString &Append + constchar *string + int32length + + + + BString &Append + charstring + int32count + + + + + Compare() + + + intCompare + constBString &string + const + + + + intCompare + constchar *string + const + + + + intCompare + constBString &string + int32n + const + + + + intCompare + constchar *string + int32n + const + + + + + CopyInto() + + + BString &CopyInto + BString &into + int32fromOffset + int32length + + + + CopyInto + char *into + int32fromOffset + int32length + + + + + CountChars() + + + int32CountCharsconst + + + + + FindFirst() + + + int32FindFirst + constBString &string + const + + + + int32FindFirst + constchar *string + const + + + + int32FindFirst + constBString &string + int32fromOffset + const + + + + int32FindFirst + constchar *string + int32fromOffset + const + + + + int32FindFirst + charcharacter + const + + + + int32FindFirst + charcharacter + int32fromOffset + const + + + + + FindLast() + + + int32FindLast + constBString &string + const + + + + int32FindLast + constchar *string + const + + + + int32FindLast + constBString &string + int32beforeOffset + const + + + + int32FindLast + constchar *string + int32beforeOffset + const + + + + int32FindLast + charcharacter + const + + + + int32FindLast + charcharacter + int32beforeOffset + const + + + + + ICompare() + + + intICompare + constBString &string + const + + + + intICompare + constchar *string + const + + + + intICompare + constBString &string + int32n + const + + + + intICompare + constchar *string + int32n + const + + + + + IFindFirst() + + + int32IFindFirst + constBString &string + const + + + + int32IFindFirst + constchar *string + const + + + + int32IFindFirst + constBString &string + int32fromOffset + const + + + + int32IFindFirst + constchar *string + int32fromOffset + const + + + + + IFindLast() + + + int32IFindLast + constBString &string + const + + + + int32IFindLast + constchar *string + const + + + + int32IFindLast + constBString &string + int32beforeOffset + const + + + + int32IFindLast + constchar *string + int32beforeOffset + const + + + + + Insert() + + + BString &Insert + constchar *string + int32pos + + + + BString &Insert + constchar *string + int32length + int32pos + + + + BString &Insert + constchar *string + int32fromOffset + int32length + int32pos + + + + BString &Insert + constBString &string + int32pos + + + + BString &Insert + constBString &string + int32length + int32pos + + + + BString &Insert + constBString &string + int32fromOffSet + int32length + int32pos + + + + BString &Inser + charstring + int32count + int32pos + + + + + Length() + + + int32Lengthconst + + + + + MoveInto() + + + BString &MoveInto + BString &into + int32from + int32length + + + + MoveInto + char *into + int32from + int32length + + + + + Prepend() + + + BString &Prepend + constBString &string + + + + BString &Prepend + constchar *string + + + + BString &Prepend + constBString &string + int32length + + + + BString &Prepend + constchar *string + int32length + + + + BString &Prepend + charstring + int32count + + + + + Remove() + + + BString &Remove + int32from + int32length + + + + + RemoveFirst() + + + BString &RemoveFirst + constBString &string + + + + BString &RemoveFirst + constchar *string + + + + + RemoveLast() + + + BString &RemoveLast + constBString &string + + + + BString &RemoveLast + constchar *string + + + + + RemoveAll + + + BString &RemoveAll + constBString &string + + + + BString &RemoveAll + constchar *string + + + + + RemoveSet + + + BString &RemoveSet + constchar *setOfCharsToRemove + + + + + SetTo + + + BString &SetTo + constchar *string + + + + BString &SetTo + constchar *string + int32length + + + + BString &SetTo + constBString &from + + + + BString &SetTo + constBString &from + int32length + + + + BString &SetTo + charstring + int32count + + + + + String() + + + const char *String const + + + + + Truncate() + + + BString &Truncate + int32newLength + boollazytrue + + + + Operators + + = (assignment) + + + BString &operator= + constBString &string + + + + BString &operator= + constchar *string + + + + BString &operator= + charstring + + + + + += (append) + + + BString &operator+= + constBString &string + + + + BString &operator+= + constchar *string + + + + BString &operator+= + constcharcharacter + + + + + <, <=, ==, >, >=, != (comparison) + + + BString &operator< + constBString &string + const + + + + BString &operator< + constchar *string + const + + + + BString &operator<= + constBString &string + const + + + + BString &operator<= + constchar *string + const + + + + BString &operator== + constBString &string + const + + + + BString &operator== + constchar *string + const + + + + BString &operator>= + constBString &string + const + + + + BString &operator>= + constchar *string + const + + + + BString &operator> + constBString &string + const + + + + BString &operator> + constchar *string + const + + + + BString &operator!= + constBString &string + const + + + + BString &operator!= + constchar *string + const + + + diff --git a/src/documentation/haiku_book/support/api.xml b/src/documentation/haiku_book/support/api.xml index 34b0d722e4..b1e7125322 100644 --- a/src/documentation/haiku_book/support/api.xml +++ b/src/documentation/haiku_book/support/api.xml @@ -1,25 +1,35 @@ - - - - - - - - - -]> - - - Support Kit API - - &archivable; - &autolock; - &blockcache; - &flattenable; - &list; - &locker; - &string; - + + + + + + + + + + + + + + +]> + + + Support Kit API + + &archivable; + &autolock; + &dataio; + &blockcache; + &flattenable; + &list; + &locker; + &mallocio; + &memoryio; + &positionio; + &stopwatch; + &string; + diff --git a/src/documentation/haiku_book/support/intro.xml b/src/documentation/haiku_book/support/intro.xml index f9cc7ea53b..0d667c3a5f 100644 --- a/src/documentation/haiku_book/support/intro.xml +++ b/src/documentation/haiku_book/support/intro.xml @@ -1,42 +1,48 @@ - - - - - Introduction - - - The Support Kit is an assortment of easy to use classes which allow a programmer to quickly extend their applications without re-writing much common functionality. Many benefits can arrise from using these classes when one starts to extend an application in the future. Functionality includes: - - - Threading utility classes: - - BLocker and BAutoLock - "Thread Local Storage" - - - - Archiving and IO: - - BArchivable - BFlattenable - BDataIO and BPositionIO - BMemoryIO and BMallocIO - - - - Container classes: - - BBlockCache - BList - BString - - - BStopWatch - Common types and constants - Error codes for all kits - - - + + + + + Introduction + + + The Support Kit is an assortment of easy to use classes which allow a programmer to quickly extend their applications without re-writing much common functionality. Many benefits can arrise from using these classes when one starts to extend an application in the future. Functionality includes: + + + Threading utility classes: + + BLocker and BAutoLock + "Thread Local Storage" + + + Archiving and IO: + + BArchivable + BFlattenable + BDataIO + + BPositionIO + + BMemoryIO + BMallocIO + + + + + + + Container classes: + + BBlockCache + BList + BString + + + BStopWatch + Common types and constants + Error codes for all kits + + +