Mundy: Multibody Nonlocal Dynamics Version of the Day
Loading...
Searching...
No Matches
mundy::mesh::SharedComponent< SharedType > Class Template Reference

A component that returns the same shared value for every entity. More...

#include <SharedComponent.hpp>

Inheritance diagram for mundy::mesh::SharedComponent< SharedType >:
[legend]

Public Types

using our_t = SharedComponent<SharedType>
using canonical_access = access::raw<SharedType>
using shared_type = SharedType
using view_t = shared_type&

Public Member Functions

 SharedComponent ()=default
 SharedComponent (shared_type shared_value)
template<typename HostViewType>
 SharedComponent (HostViewType host_view)
 SharedComponent (const SharedComponent &)=default
 SharedComponent (SharedComponent &&)=default
SharedComponentoperator= (const SharedComponent &)=default
SharedComponentoperator= (SharedComponent &&)=default
decltype(auto) operator() (stk::mesh::Entity) const
shared_typeshared_value ()
const shared_typeshared_value () const
void sync_to_device ()
void sync_to_host ()
void modify_on_device ()
void modify_on_host ()
void clear_host_sync_state ()
void clear_device_sync_state ()
void set_declaration_metadata (std::string name, stk::mesh::EntityRank rank)
const std::string & name () const
stk::mesh::EntityRank entity_rank () const

Friends

template<typename NgpMemSpace, typename OtherSharedType>
NgpSharedComponent< OtherSharedType, NgpMemSpace > & get_updated_ngp_component (const SharedComponent< OtherSharedType > &component)

Detailed Description

template<typename SharedType>
class mundy::mesh::SharedComponent< SharedType >

Construct either from:

  • a raw SharedType, which is copied into owned HostSpace storage
  • a rank-1 Kokkos::View in HostSpace with extent 1, which is aliased exactly as given whether that view is managed or unmanaged

Member Typedef Documentation

◆ our_t

template<typename SharedType>
using mundy::mesh::SharedComponent< SharedType >::our_t = SharedComponent<SharedType>

◆ canonical_access

template<typename SharedType>
using mundy::mesh::SharedComponent< SharedType >::canonical_access = access::raw<SharedType>

◆ shared_type

template<typename SharedType>
using mundy::mesh::SharedComponent< SharedType >::shared_type = SharedType

◆ view_t

template<typename SharedType>
using mundy::mesh::SharedComponent< SharedType >::view_t = shared_type&

Constructor & Destructor Documentation

◆ SharedComponent() [1/5]

template<typename SharedType>
mundy::mesh::SharedComponent< SharedType >::SharedComponent ( )
default

◆ SharedComponent() [2/5]

template<typename SharedType>
mundy::mesh::SharedComponent< SharedType >::SharedComponent ( shared_type shared_value)
inlineexplicit

◆ SharedComponent() [3/5]

template<typename SharedType>
template<typename HostViewType>
mundy::mesh::SharedComponent< SharedType >::SharedComponent ( HostViewType host_view)
inlineexplicit

◆ SharedComponent() [4/5]

template<typename SharedType>
mundy::mesh::SharedComponent< SharedType >::SharedComponent ( const SharedComponent< SharedType > & )
default

◆ SharedComponent() [5/5]

template<typename SharedType>
mundy::mesh::SharedComponent< SharedType >::SharedComponent ( SharedComponent< SharedType > && )
default

Member Function Documentation

◆ operator=() [1/2]

template<typename SharedType>
SharedComponent & mundy::mesh::SharedComponent< SharedType >::operator= ( const SharedComponent< SharedType > & )
default

◆ operator=() [2/2]

template<typename SharedType>
SharedComponent & mundy::mesh::SharedComponent< SharedType >::operator= ( SharedComponent< SharedType > && )
default

◆ operator()()

template<typename SharedType>
decltype(auto) mundy::mesh::SharedComponent< SharedType >::operator() ( stk::mesh::Entity ) const
inline

◆ shared_value() [1/2]

template<typename SharedType>
shared_type & mundy::mesh::SharedComponent< SharedType >::shared_value ( )
inline

◆ shared_value() [2/2]

template<typename SharedType>
const shared_type & mundy::mesh::SharedComponent< SharedType >::shared_value ( ) const
inline

◆ sync_to_device()

template<typename SharedType>
void mundy::mesh::SharedComponent< SharedType >::sync_to_device ( )
inline

◆ sync_to_host()

template<typename SharedType>
void mundy::mesh::SharedComponent< SharedType >::sync_to_host ( )
inline

◆ modify_on_device()

template<typename SharedType>
void mundy::mesh::SharedComponent< SharedType >::modify_on_device ( )
inline

◆ modify_on_host()

template<typename SharedType>
void mundy::mesh::SharedComponent< SharedType >::modify_on_host ( )
inline

◆ clear_host_sync_state()

template<typename SharedType>
void mundy::mesh::SharedComponent< SharedType >::clear_host_sync_state ( )
inline

◆ clear_device_sync_state()

template<typename SharedType>
void mundy::mesh::SharedComponent< SharedType >::clear_device_sync_state ( )
inline

◆ set_declaration_metadata()

template<typename SharedType>
void mundy::mesh::SharedComponent< SharedType >::set_declaration_metadata ( std::string name,
stk::mesh::EntityRank rank )
inline

◆ name()

template<typename SharedType>
const std::string & mundy::mesh::SharedComponent< SharedType >::name ( ) const
inline

◆ entity_rank()

template<typename SharedType>
stk::mesh::EntityRank mundy::mesh::SharedComponent< SharedType >::entity_rank ( ) const
inline

◆ get_updated_ngp_component

template<typename SharedType>
template<typename NgpMemSpace, typename OtherSharedType>
NgpSharedComponent< OtherSharedType, NgpMemSpace > & get_updated_ngp_component ( const SharedComponent< OtherSharedType > & component)
friend