pub struct SimilarityRenderContext { /* private fields */ }Expand description
Holds the views used to display a similarity result.
Implementations§
Source§impl SimilarityRenderContext
impl SimilarityRenderContext
pub unsafe fn from_raw(handle: *mut BNSimilarityRenderContext) -> Self
pub unsafe fn ref_from_raw(handle: *mut BNSimilarityRenderContext) -> Ref<Self>
Sourcepub fn set_preferred_view_type(&self, view_type: FunctionViewType)
pub fn set_preferred_view_type(&self, view_type: FunctionViewType)
Sets the function representation preferred by renderers writing to this context.
Sourcepub fn preferred_view_type(&self) -> FunctionViewType
pub fn preferred_view_type(&self) -> FunctionViewType
Returns the function representation preferred by renderers writing to this context.
Sourcepub fn add_flow_graph(&self, group: &str, graph: &FlowGraph)
pub fn add_flow_graph(&self, group: &str, graph: &FlowGraph)
Adds a flow graph to a view group.
Sourcepub fn add_flow_graph_for_entity(
&self,
group: &str,
graph: &FlowGraph,
entity: SimilarityEntityRef,
)
pub fn add_flow_graph_for_entity( &self, group: &str, graph: &FlowGraph, entity: SimilarityEntityRef, )
Adds a flow graph for a session entity to a view group.
Sourcepub fn add_linear_view(
&self,
group: &str,
data: &BinaryView,
linear_view: &LinearViewObject,
)
pub fn add_linear_view( &self, group: &str, data: &BinaryView, linear_view: &LinearViewObject, )
Adds a linear view to a view group.
Sourcepub fn add_linear_view_for_entity(
&self,
group: &str,
data: &BinaryView,
linear_view: &LinearViewObject,
entity: SimilarityEntityRef,
)
pub fn add_linear_view_for_entity( &self, group: &str, data: &BinaryView, linear_view: &LinearViewObject, entity: SimilarityEntityRef, )
Adds a linear view for a session entity to a view group.
Sourcepub fn views(&self) -> Vec<SimilarityView>
pub fn views(&self) -> Vec<SimilarityView>
Returns the views in insertion order.
Trait Implementations§
Source§impl ToOwned for SimilarityRenderContext
impl ToOwned for SimilarityRenderContext
Source§type Owned = Ref<SimilarityRenderContext>
type Owned = Ref<SimilarityRenderContext>
The resulting type after obtaining ownership.
Source§fn to_owned(&self) -> Self::Owned
fn to_owned(&self) -> Self::Owned
Creates owned data from borrowed data, usually by cloning. Read more
1.63.0 · Source§fn clone_into(&self, target: &mut Self::Owned)
fn clone_into(&self, target: &mut Self::Owned)
Uses borrowed data to replace owned data, usually by cloning. Read more
Auto Trait Implementations§
impl Freeze for SimilarityRenderContext
impl RefUnwindSafe for SimilarityRenderContext
impl !Send for SimilarityRenderContext
impl !Sync for SimilarityRenderContext
impl Unpin for SimilarityRenderContext
impl UnsafeUnpin for SimilarityRenderContext
impl UnwindSafe for SimilarityRenderContext
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more