pub struct RegexMatches { /* private fields */ }Expand description
The rows of one regexp_matches call. Like PostgreSQL’s first call, preparing the cursor finds every match; the cursor owns the input’s code points and the match spans, so a caller can draw each row under its own control.
Implementations§
Source§impl RegexMatches
impl RegexMatches
Sourcepub fn new(
arguments: &[Value],
collation: u32,
control: &ProductionControl<'_>,
) -> Result<Option<Self>>
pub fn new( arguments: &[Value], collation: u32, control: &ProductionControl<'_>, ) -> Result<Option<Self>>
Prepare regexp_matches(string, pattern [, flags]) under the call’s input collation (PostgreSQL’s inputcollid, zero when indeterminate). A NULL argument yields no cursor: the strict set-returning function returns no rows.
§Errors
Reports PostgreSQL’s diagnostics for an invalid flag, collation or pattern and for a failed search, an exhausted allowance and cancellation.
Sourcepub fn next_row(
&mut self,
control: &ProductionControl<'_>,
) -> Result<Option<Produced<Value>>>
pub fn next_row( &mut self, control: &ProductionControl<'_>, ) -> Result<Option<Produced<Value>>>
The capture array of the next match, or None after the last one.
§Errors
Reports an exhausted allowance or cancellation. The cursor stays at the failed match, and rows already returned remain valid.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for RegexMatches
impl RefUnwindSafe for RegexMatches
impl Send for RegexMatches
impl Sync for RegexMatches
impl Unpin for RegexMatches
impl UnsafeUnpin for RegexMatches
impl UnwindSafe for RegexMatches
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
impl<T> ErasedDestructor for Twhere
T: 'static,
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> ⓘ
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> ⓘ
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