Skip to content
This repository was archived by the owner on Aug 28, 2024. It is now read-only.

Commit

Permalink
Refactored some of the storage procedure names to keep the naming sch…
Browse files Browse the repository at this point in the history
…eme somewhat consistent
  • Loading branch information
daminton committed Dec 1, 2022
1 parent 7d48f80 commit 01762bf
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 10 deletions.
4 changes: 2 additions & 2 deletions src/io/io.f90
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ module subroutine io_dump_system(self, param)
end subroutine io_dump_system


module subroutine io_dump_system_storage(self, param)
module subroutine io_dump_storage_system(self, param)
!! author: David A. Minton
!!
!! Dumps the time history of the simulation to file. Each time it writes a frame to file, it deallocates the system
Expand All @@ -295,7 +295,7 @@ module subroutine io_dump_system_storage(self, param)
end do

return
end subroutine io_dump_system_storage
end subroutine io_dump_storage_system


module subroutine io_get_args(integrator, param_file_name, display_style)
Expand Down
2 changes: 1 addition & 1 deletion src/modules/encounter_classes.f90
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ module encounter_classes
procedure :: dealloc => encounter_util_dealloc_list !! Deallocates all allocatables
procedure :: spill => encounter_util_spill_list !! "Spills" bodies from one object to another depending on the results of a mask (uses the PACK intrinsic)
procedure :: resize => encounter_util_resize_list !! Checks the current size of the encounter list against the required size and extends it by a factor of 2 more than requested if it is too small.
final :: encounter_util_final_list !! Finalize the encounter list - deallocates all allocatables
final :: encounter_util_final_list !! Finalize the encounter list - deallocates all allocatables
end type encounter_list

type encounter_bounding_box_1D
Expand Down
12 changes: 6 additions & 6 deletions src/modules/swiftest_classes.f90
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ module swiftest_classes
generic :: write_frame => write_frame_system, write_frame_netcdf !! Generic method call for reading a frame of output data
end type swiftest_nbody_system

type storage_frame
type swiftest_storage_frame_system
class(swiftest_nbody_system), allocatable :: system
contains
procedure :: store => util_copy_store_system !! Stores a snapshot of the nbody system so that later it can be retrieved for saving to file.
Expand All @@ -427,9 +427,9 @@ module swiftest_classes
type, extends(swiftest_base) :: swiftest_storage(nframes)
integer(I4B), len :: nframes
!! A class that that is used to store simulation history data between file output
type(storage_frame), dimension(nframes) :: frame
type(swiftest_storage_frame_system), dimension(nframes) :: frame
contains
procedure :: dump => io_dump_system_storage
procedure :: dump => io_dump_storage_system
end type swiftest_storage

abstract interface
Expand Down Expand Up @@ -626,11 +626,11 @@ module subroutine io_dump_system(self, param)
end subroutine io_dump_system


module subroutine io_dump_system_storage(self, param)
module subroutine io_dump_storage_system(self, param)
implicit none
class(swiftest_storage(*)), intent(inout) :: self !! Swiftest simulation history storage object
class(swiftest_parameters), intent(inout) :: param !! Current run configuration parameters
end subroutine io_dump_system_storage
end subroutine io_dump_storage_system

module subroutine io_get_args(integrator, param_file_name, display_style)
implicit none
Expand Down Expand Up @@ -1245,7 +1245,7 @@ end subroutine util_copy_particle_info_arr

module subroutine util_copy_store_system(self, system)
implicit none
class(storage_frame), intent(inout) :: self !! Swiftest storage frame object
class(swiftest_storage_frame_system), intent(inout) :: self !! Swiftest storage frame object
class(swiftest_nbody_system), intent(in) :: system !! Swiftest n-body system object
end subroutine util_copy_store_system

Expand Down
2 changes: 1 addition & 1 deletion src/util/util_copy.f90
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ module subroutine util_copy_store_system(self, system)
!!
!! Stores a snapshot of the nbody system so that later it can be retrieved for saving to file.
implicit none
class(storage_frame), intent(inout) :: self !! Swiftest storage frame object
class(swiftest_storage_frame_system), intent(inout) :: self !! Swiftest storage frame object
class(swiftest_nbody_system), intent(in) :: system !! Swiftest n-body system object

if (allocated(self%system)) deallocate(self%system)
Expand Down

0 comments on commit 01762bf

Please sign in to comment.