Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
tnl-dev
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
TNL
tnl-dev
Commits
0a7815cd
There was an error fetching the commit references. Please try again later.
Commit
0a7815cd
authored
6 years ago
by
Nina Džugasová
Browse files
Options
Downloads
Patches
Plain Diff
Fixed String documentation.
parent
929b7675
No related branches found
No related tags found
1 merge request
!15
Nina
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/TNL/String.h
+18
-16
18 additions, 16 deletions
src/TNL/String.h
with
18 additions
and
16 deletions
src/TNL/String.h
+
18
−
16
View file @
0a7815cd
...
...
@@ -48,6 +48,7 @@ class String
/// Constructs a string initialized with the 8-bit string \e c, excluding
/// the given number of \e prefix_cut_off and \e sufix_cut_off characters.
///
/// @param c Pointer to an array of characters.
/// @param prefix_cut_off Determines the length of the prefix that is going
/// to be omitted from the string \e c.
/// @param sufix_cut_off Determines the length of the sufix that is going
...
...
@@ -61,13 +62,14 @@ class String
int
prefix_cut_off
=
0
,
int
sufix_cut_off
=
0
);
/// Returns type of string - String.
///
\brief
Returns type of string - String.
static
String
getType
();
/////
/// \brief Copy constructor.
///
/// Constructs a copy of the string \e str.
/// @param str Another string object, whose value is copied.
String
(
const
String
&
str
);
/// \brief Converts anything to a string.
...
...
@@ -96,7 +98,7 @@ class String
/// \include StringExampleGetSize.out
int
getSize
()
const
;
/// Returns size of allocated storage for given string.
///
\brief
Returns size of allocated storage for given string.
///
/// \par Example
/// \include StringExampleGetAllocatedSize.cpp
...
...
@@ -175,23 +177,23 @@ class String
/////
// Operators for Strings.
/// This function assigns \e str to this string and returns a reference to
///
\brief
This function assigns \e str to this string and returns a reference to
/// this string.
String
&
operator
=
(
const
String
&
str
);
/// This function appends the string \e str onto the end of this string
///
\brief
This function appends the string \e str onto the end of this string
/// and returns a reference to this string.
String
&
operator
+=
(
const
String
&
str
);
/// This function concatenates strings \e str and returns a newly
///
\brief
This function concatenates strings \e str and returns a newly
/// constructed string object.
String
operator
+
(
const
String
&
str
)
const
;
/// \brief This function overloads operator==().
///
///
It r
eturns \c true if this string is equal to \e str, otherwise returns
///
R
eturns \c true if this string is equal to \e str, otherwise returns
/// \c false.
bool
operator
==
(
const
String
&
str
)
const
;
/// \brief This function overloads operator!=().
///
///
It r
eturns \c true if this string is not equal to \e str, otherwise
///
R
eturns \c true if this string is not equal to \e str, otherwise
/// returns \c false.
bool
operator
!=
(
const
String
&
str
)
const
;
...
...
@@ -200,15 +202,15 @@ class String
/// \brief This function overloads operator=().
///
///
It a
ssigns character \e str to this string.
///
A
ssigns character \e str to this string.
String
&
operator
=
(
char
str
);
/// \brief This function overloads operator+=().
///
///
It a
ppends character \e str to this string.
///
A
ppends character \e str to this string.
String
&
operator
+=
(
char
str
);
// This function concatenates strings and returns a newly constructed string object.
//
\brief
This function concatenates strings and returns a newly constructed string object.
String
operator
+
(
char
str
)
const
;
// This function concatenates strings and returns a newly constructed string object.
//
\brief
This function concatenates strings and returns a newly constructed string object.
bool
operator
==
(
char
str
)
const
;
/// \brief This function overloads operator!=().
bool
operator
!=
(
char
str
)
const
;
...
...
@@ -280,21 +282,21 @@ class String
protected
:
/// Pointer to char ended with zero byte
///
\brief
Pointer to char ended with zero byte
.
char
*
string
;
/// Length of allocated piece of memory.
///
\brief
Length of allocated piece of memory.
int
length
;
};
// class String
/// Returns concatenation of \e string1 and \e string2.
///
\brief
Returns concatenation of \e string1 and \e string2.
String
operator
+
(
char
string1
,
const
String
&
string2
);
/// Returns concatenation of \e string1 and \e string2.
///
\brief
Returns concatenation of \e string1 and \e string2.
String
operator
+
(
const
char
*
string1
,
const
String
&
string2
);
/// Performs the string output to a stream
///
\brief
Performs the string output to a stream
std
::
ostream
&
operator
<<
(
std
::
ostream
&
stream
,
const
String
&
str
);
template
<
typename
T
>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment