sp_reference_counter_t Derived Type

type, public :: sp_reference_counter_t


Inherits

type~~sp_reference_counter_t~~InheritsGraph type~sp_reference_counter_t sp_reference_counter_t type~sp_resource_t sp_resource_t type~sp_reference_counter_t->type~sp_resource_t object_

Inherited by

type~~sp_reference_counter_t~~InheritedByGraph type~sp_reference_counter_t sp_reference_counter_t type~sp_smart_pointer_t sp_smart_pointer_t type~sp_smart_pointer_t->type~sp_reference_counter_t counter

Contents


Components

TypeVisibilityAttributesNameInitial
integer, private, pointer:: count_=> null()
class(sp_resource_t), private, pointer:: object_=> null()

Constructor

public interface sp_reference_counter_t

  • private module function construct(object) result(sp_reference_counter)

    Arguments

    TypeIntentOptionalAttributesName
    class(sp_resource_t), intent(in) :: object

    Return Value type(sp_reference_counter_t)


Finalization Procedures

final :: finalize


Type-Bound Procedures

procedure, public :: assign_sp_reference_counter

generic, public :: assignment(=) => assign_sp_reference_counter

procedure, public, non_overridable :: grab

procedure, public :: reference_count

  • interface

    private pure module module function reference_count(self) result(counter)

    Arguments

    TypeIntentOptionalAttributesName
    class(sp_reference_counter_t), intent(in) :: self

    Return Value integer

procedure, public, non_overridable :: release