package MyClass; use Moo; has attribute1 => ( is => 'ro' ); has attribute2 => ( is => 'rw' );