Lines Matching full:self

47     pub fn name(&self) -> &str {  in name()
51 self.ptr, in name()
74 pub fn size(&self) -> usize { in size()
77 bind_ceed::CeedQFunctionFieldGetSize(self.ptr, &mut size); in size()
106 pub fn eval_mode(&self) -> crate::EvalMode { in eval_mode()
109 bind_ceed::CeedQFunctionFieldGetEvalMode(self.ptr, &mut mode); in eval_mode()
126 fn from(qfunc: &'a QFunction) -> Self { in from() argument
128 Self::SomeQFunction(qfunc) in from()
134 fn from(qfunc: &'a QFunctionByName) -> Self { in from() argument
136 Self::SomeQFunctionByName(qfunc) in from()
142 pub(crate) fn to_raw(&self) -> bind_ceed::CeedQFunction { in to_raw()
143 match self { in to_raw()
144 Self::SomeQFunction(qfunc) => qfunc.qf_core.ptr, in to_raw()
145 Self::SomeQFunctionByName(qfunc) => qfunc.qf_core.ptr, in to_raw()
146 Self::None => unsafe { bind_ceed::CEED_QFUNCTION_NONE }, in to_raw()
183 pub fn is_some(&self) -> bool { in is_some()
184 match self { in is_some()
185 Self::SomeQFunction(_) => true, in is_some()
186 Self::SomeQFunctionByName(_) => true, in is_some()
187 Self::None => false, in is_some()
224 pub fn is_some_q_function(&self) -> bool { in is_some_q_function()
225 match self { in is_some_q_function()
226 Self::SomeQFunction(_) => true, in is_some_q_function()
227 Self::SomeQFunctionByName(_) => false, in is_some_q_function()
228 Self::None => false, in is_some_q_function()
274 pub fn is_some_q_function_by_name(&self) -> bool { in is_some_q_function_by_name()
275 match self { in is_some_q_function_by_name()
276 Self::SomeQFunction(_) => false, in is_some_q_function_by_name()
277 Self::SomeQFunctionByName(_) => true, in is_some_q_function_by_name()
278 Self::None => false, in is_some_q_function_by_name()
315 pub fn is_none(&self) -> bool { in is_none()
316 match self { in is_none()
317 Self::SomeQFunction(_) => false, in is_none()
318 Self::SomeQFunctionByName(_) => false, in is_none()
319 Self::None => true, in is_none()
356 fn drop(&mut self) { in drop() argument
358 if self.ptr != bind_ceed::CEED_QFUNCTION_NONE { in drop()
359 bind_ceed::CeedQFunctionDestroy(&mut self.ptr); in drop()
366 fn drop(&mut self) { in drop() argument
368 bind_ceed::CeedQFunctionContextDestroy(&mut self.qf_ctx_ptr); in drop()
377 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { in fmt() argument
382 bind_ceed::CeedQFunctionView(self.ptr, file); in fmt()
416 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { in fmt() argument
417 self.qf_core.fmt(f) in fmt()
433 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { in fmt() argument
434 self.qf_core.fmt(f) in fmt()
444 fn ceed(&self) -> bind_ceed::Ceed { in ceed()
445 unsafe { bind_ceed::CeedQFunctionReturnCeed(self.ptr) } in ceed()
450 fn check_error(&self, ierr: i32) -> crate::Result<i32> { in check_error() argument
451 crate::check_error(|| self.ceed(), ierr) in check_error()
455 pub fn apply(&self, Q: usize, u: &[Vector], v: &[Vector]) -> crate::Result<i32> { in apply() argument
465 self.check_error(unsafe { in apply()
466 bind_ceed::CeedQFunctionApply(self.ptr, Q, u_c.as_mut_ptr(), v_c.as_mut_ptr()) in apply()
470 pub fn inputs(&self) -> crate::Result<&[QFunctionField]> { in inputs()
474 self.check_error(unsafe { in inputs()
476 self.ptr, in inputs()
490 pub fn outputs(&self) -> crate::Result<&[QFunctionField]> { in outputs()
494 self.check_error(unsafe { in outputs()
496 self.ptr, in outputs()
578 ) -> crate::Result<Self> { in create() argument
628 Ok(Self { in create()
699 pub fn apply(&self, Q: usize, u: &[Vector], v: &[Vector]) -> crate::Result<i32> { in apply() argument
700 self.qf_core.apply(Q, u, v) in apply()
734 mut self, in input() argument
738 ) -> crate::Result<Self> { in input() argument
740 let idx = self.trampoline_data.number_inputs; in input()
741 self.trampoline_data.input_sizes[idx] = size; in input()
742 self.trampoline_data.number_inputs += 1; in input()
747 self.qf_core.check_error(unsafe { in input()
748 bind_ceed::CeedQFunctionAddInput(self.qf_core.ptr, name_c.as_ptr(), size, emode) in input()
750 Ok(self) in input()
783 mut self, in output() argument
787 ) -> crate::Result<Self> { in output() argument
789 let idx = self.trampoline_data.number_outputs; in output()
790 self.trampoline_data.output_sizes[idx] = size; in output()
791 self.trampoline_data.number_outputs += 1; in output()
796 self.qf_core.check_error(unsafe { in output()
797 bind_ceed::CeedQFunctionAddOutput(self.qf_core.ptr, name_c.as_ptr(), size, emode) in output()
799 Ok(self) in output()
829 pub fn inputs(&self) -> crate::Result<&[QFunctionField]> { in inputs()
830 self.qf_core.inputs() in inputs()
859 pub fn outputs(&self) -> crate::Result<&[QFunctionField]> { in outputs()
860 self.qf_core.outputs() in outputs()
869 pub fn create(ceed: &crate::Ceed, name: &str) -> crate::Result<Self> { in create() argument
875 Ok(Self { in create()
944 pub fn apply(&self, Q: usize, u: &[Vector], v: &[Vector]) -> crate::Result<i32> { in apply() argument
945 self.qf_core.apply(Q, u, v) in apply()
963 pub fn inputs(&self) -> crate::Result<&[QFunctionField]> { in inputs()
964 self.qf_core.inputs() in inputs()
982 pub fn outputs(&self) -> crate::Result<&[QFunctionField]> { in outputs()
983 self.qf_core.outputs() in outputs()