Skip to content

flap_object_t ​

Base (abstract) class upon which FLAP's concrete classes are built.

Source: src/lib/flap_object_t.F90

Dependencies

Contents ​

Derived Types ​

object ​

Base (abstract) class upon which FLAP's concrete classes are built.

Inheritance

Attributes: abstract

Components ​

NameTypeAttributesDescription
prognamecharacter(len=:)allocatableProgram name.
versioncharacter(len=:)allocatableProgram version.
helpcharacter(len=:)allocatableHelp message.
help_colorcharacter(len=:)allocatableANSI color of help messages.
help_stylecharacter(len=:)allocatableANSI style of help messages.
help_markdowncharacter(len=:)allocatableLonger help message, markdown formatted.
descriptioncharacter(len=:)allocatableDetailed description.
licensecharacter(len=:)allocatableLicense description.
authorscharacter(len=:)allocatableAuthors list.
epilogcharacter(len=:)allocatableEpilogue message.
m_excludecharacter(len=:)allocatableMutually exclude other CLA(s group).
error_messagecharacter(len=:)allocatableMeaningful error message to standard-error.
error_colorcharacter(len=:)allocatableANSI color of error messages.
error_stylecharacter(len=:)allocatableANSI style of error messages.
examplestype(flap_string)allocatableExamples of correct usage (examples(i)%s).
errorinteger(kind=I4P)Error trapping flag.
usage_luninteger(kind=I4P)Output unit to print help/usage messages
version_luninteger(kind=I4P)Output unit to print version message
error_luninteger(kind=I4P)Error unit to print error messages
case_insensitivelogicalMatch switches and command names in any case (F14).

Type-Bound Procedures ​

NameAttributesDescription
error_prefixpass(self)Prefix of error messages.
free_objectpass(self)Free dynamic memory.
print_versionpass(self)Print version.
print_error_messagepass(self)Print meaningful error message.
inherit_errorpass(self)Take the error of another object, with its message.
clear_errorpass(self)Forget the error and its message.
set_examplespass(self)Set examples of correct usage.
assign_objectpass(lhs )Assignment overloading.

Subroutines ​

free_object ​

Free dynamic memory.

Attributes: elemental

fortran
subroutine free_object(self)

Arguments

NameTypeIntentAttributesDescription
selfclass(object)inoutObject data.

Call graph

Print version.

fortran
subroutine print_version(self, pref)

Arguments

NameTypeIntentAttributesDescription
selfclass(object)inObject data.
prefcharacter(len=*)inoptionalPrefixing string.

Call graph

Print meaningful error message to standard-error.

fortran
subroutine print_error_message(self)

Arguments

NameTypeIntentAttributesDescription
selfclass(object)inObject data.

Call graph

set_examples ​

Set the examples of correct usage: exactly the given ones, or none.

fortran
subroutine set_examples(self, examples)

Arguments

NameTypeIntentAttributesDescription
selfclass(object)inoutObject data.
examplescharacter(len=*)inoptionalExamples of correct usage.

Call graph

inherit_error ​

Take the error of another object, with its message: the error of an argument is reported by its group, the one of a group by the CLI, whose error_message is then the message of its error. A status (not positive) has no message.

Attributes: pure

fortran
subroutine inherit_error(self, from)

Arguments

NameTypeIntentAttributesDescription
selfclass(object)inoutObject data.
fromclass(object)inObject that raised the error.

Call graph

clear_error ​

Forget the error and its message.

Attributes: pure

fortran
subroutine clear_error(self)

Arguments

NameTypeIntentAttributesDescription
selfclass(object)inoutObject data.

Call graph

assign_object ​

Assign two abstract objects.

Attributes: elemental

fortran
subroutine assign_object(lhs, rhs)

Arguments

NameTypeIntentAttributesDescription
lhsclass(object)inoutLeft hand side.
rhsclass(object)inRigth hand side.

Call graph

Functions ​

error_prefix ​

Return the prefix of every error message: the prefixing string, the program name and a (colorized) "error".

Returns: character(len=:)

fortran
function error_prefix(self, pref) result(prefd)

Arguments

NameTypeIntentAttributesDescription
selfclass(object)inObject data.
prefcharacter(len=*)inoptionalPrefixing string.

Call graph