pub struct AtomicSentence { /* private fields */ }
Expand description
Corresponds to the grammar rule atomic_sentence
.
An AtomicSentence
has a predicate term and an ordered list of terms corresponding
to the predicate arguments.
Implementations§
Source§impl AtomicSentence
impl AtomicSentence
pub fn new<T>(predicate: T) -> Self
pub fn new_with_arguments<T, I>(predicate: T, arguments: I) -> Self
pub const fn predicate(&self) -> &Term
pub fn set_predicate(&mut self, predicate: Term)
pub fn has_arguments(&self) -> bool
pub fn arguments_len(&self) -> usize
pub fn arguments(&self) -> impl Iterator<Item = &Term>
pub fn arguments_mut(&mut self) -> impl Iterator<Item = &mut Term>
pub fn add_to_arguments<I>(&mut self, value: I)
pub fn extend_arguments<I>(&mut self, extension: I)where
I: IntoIterator<Item = Term>,
Trait Implementations§
Source§impl Clone for AtomicSentence
impl Clone for AtomicSentence
Source§fn clone(&self) -> AtomicSentence
fn clone(&self) -> AtomicSentence
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for AtomicSentence
impl Debug for AtomicSentence
Source§impl<'de> Deserialize<'de> for AtomicSentence
impl<'de> Deserialize<'de> for AtomicSentence
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<&AtomicSentence> for SimpleSentence
impl From<&AtomicSentence> for SimpleSentence
Source§fn from(v: &AtomicSentence) -> Self
fn from(v: &AtomicSentence) -> Self
Converts to this type from the input type.
Source§impl From<AtomicSentence> for SimpleSentence
impl From<AtomicSentence> for SimpleSentence
Source§fn from(v: AtomicSentence) -> Self
fn from(v: AtomicSentence) -> Self
Converts to this type from the input type.
Source§impl HasSourceSpan for AtomicSentence
impl HasSourceSpan for AtomicSentence
fn with_source_span(self, span: Span) -> Self
fn source_span(&self) -> Option<&Span>
fn set_source_span(&mut self, span: Span)
fn unset_source_span(&mut self)
fn has_source_span(&self) -> bool
Auto Trait Implementations§
impl Freeze for AtomicSentence
impl RefUnwindSafe for AtomicSentence
impl Send for AtomicSentence
impl Sync for AtomicSentence
impl Unpin for AtomicSentence
impl UnwindSafe for AtomicSentence
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