Re: [Bioc-devel] Adding additional validity checks when calling setter methods of inherited S4Vectors::DataFrame class

2025-01-04 Thread Pariksheet Nanda via Bioc-devel
Hi Lluís, > So your setter method `[<-` could have this call inside it, and this > would prevent the creation of an invalid object. Thank you for solving my issue! I wasn't successful trying something similar earlier because I was passing no arguments to callNextMethod(), but retrying your s

Re: [Bioc-devel] Adding additional validity checks when calling setter methods of inherited S4Vectors::DataFrame class

2025-01-04 Thread Lluís Revilla
Hi Pariksheet, You can check if the object is valid inside your methods. I use something like: method <- function(...) { # Input processing validObject(object) object } So your setter method `[<-` could have this call inside it, and this would prevent the creation of an invalid obje