Struct py_raphtory::vertex::PyVertices
source · pub struct PyVertices { /* private fields */ }Expand description
A list of vertices that can be iterated over.
Implementations§
source§impl PyVertices
impl PyVertices
Operations on a list of vertices. These use all the same functions as a normal vertex except it returns a list of results.
pub fn start(&self) -> Option<i64>
pub fn end(&self) -> Option<i64>
sourcepub fn window_size(&self) -> Option<u64>
pub fn window_size(&self) -> Option<u64>
Returns the size of the window covered by this view
Returns: int: the size of the window
pub fn window( &self, t_start: Option<&PyAny>, t_end: Option<&PyAny> ) -> PyResult<PyVertices>
sourcepub fn at(&self, end: &PyAny) -> PyResult<PyVertices>
pub fn at(&self, end: &PyAny) -> PyResult<PyVertices>
Create a view of the vertices including all events at t.
Arguments: end (int): The time of the window.
Returns:
A PyVertices object.
sourcepub fn default_layer(&self) -> PyVertices
pub fn default_layer(&self) -> PyVertices
Create a view including all the edges in the default layer
Returns: a view including all the edges in the default layer
sourcepub fn layer(&self, name: &str) -> Option<PyVertices>
pub fn layer(&self, name: &str) -> Option<PyVertices>
Create a view including all the edges in the layer name
Arguments: name (str) : the name of the layer
Returns:
a view including all the edges in the layer name
pub fn __iter__(&self) -> PyVertexIterator
pub fn __len__(&self) -> usize
pub fn __bool__(&self) -> bool
pub fn __getitem__(&self, vertex: &PyAny) -> PyResult<PyVertex>
pub fn __call__(slf: PyRef<'_, Self>) -> PyRef<'_, Self>
pub fn __repr__(&self) -> String
Trait Implementations§
source§impl<G: GraphViewOps + IntoDynamic> From<Vertices<G>> for PyVertices
impl<G: GraphViewOps + IntoDynamic> From<Vertices<G>> for PyVertices
source§impl PyClassImpl for PyVertices
impl PyClassImpl for PyVertices
source§const IS_BASETYPE: bool = false
const IS_BASETYPE: bool = false
#[pyclass(subclass)]
source§const IS_SUBCLASS: bool = false
const IS_SUBCLASS: bool = false
#[pyclass(extends=…)]
source§const IS_MAPPING: bool = false
const IS_MAPPING: bool = false
#[pyclass(mapping)]
source§const IS_SEQUENCE: bool = false
const IS_SEQUENCE: bool = false
#[pyclass(sequence)]
§type Layout = PyCell<PyVertices>
type Layout = PyCell<PyVertices>
Layout
§type ThreadChecker = ThreadCheckerStub<PyVertices>
type ThreadChecker = ThreadCheckerStub<PyVertices>
This handles following two situations: Read more
type Inventory = Pyo3MethodsInventoryForPyVertices
§type PyClassMutability = <<PyAny as PyClassBaseType>::PyClassMutability as PyClassMutability>::MutableChild
type PyClassMutability = <<PyAny as PyClassBaseType>::PyClassMutability as PyClassMutability>::MutableChild
Immutable or mutable
§type BaseNativeType = PyAny
type BaseNativeType = PyAny
The closest native ancestor. This is
PyAny by default, and when you declare
#[pyclass(extends=PyDict)], it’s PyDict.fn items_iter() -> PyClassItemsIter
fn lazy_type_object() -> &'static LazyTypeObject<Self>
fn dict_offset() -> Option<isize>
fn weaklist_offset() -> Option<isize>
source§impl<'a, 'py> PyFunctionArgument<'a, 'py> for &'a PyVertices
impl<'a, 'py> PyFunctionArgument<'a, 'py> for &'a PyVertices
source§impl<'a, 'py> PyFunctionArgument<'a, 'py> for &'a mut PyVertices
impl<'a, 'py> PyFunctionArgument<'a, 'py> for &'a mut PyVertices
source§impl PyTypeInfo for PyVertices
impl PyTypeInfo for PyVertices
§type AsRefTarget = PyCell<PyVertices>
type AsRefTarget = PyCell<PyVertices>
Utility type to make Py::as_ref work.
source§fn type_object_raw(py: Python<'_>) -> *mut PyTypeObject
fn type_object_raw(py: Python<'_>) -> *mut PyTypeObject
Returns the PyTypeObject instance for this type.
source§fn type_object(py: Python<'_>) -> &PyType
fn type_object(py: Python<'_>) -> &PyType
Returns the safe abstraction over the type object.
source§fn is_type_of(object: &PyAny) -> bool
fn is_type_of(object: &PyAny) -> bool
Checks if
object is an instance of this type or a subclass of this type.source§fn is_exact_type_of(object: &PyAny) -> bool
fn is_exact_type_of(object: &PyAny) -> bool
Checks if
object is an instance of this type.Auto Trait Implementations§
impl !RefUnwindSafe for PyVertices
impl Send for PyVertices
impl Sync for PyVertices
impl Unpin for PyVertices
impl !UnwindSafe for PyVertices
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more