All parameter values are strings in Java view, viz. setValue expects a string
// Get UnitOfWork
IUnitOfWork uow=self.getUnitOfWOrk();
// Set parameter
((MechatronicObject) selectedEOs.get(0)).getParameter("Option_Inspection_available").setValue("true");
If formulas are set as paramter values, in opposite to setValue setPrettyValue should be used: Thus absolute type names become rugged against renaming the referenced classes.
// Get UnitOfWork
uow=self.getUnitOfWOrk();
// Set parameter
selectedEOs.get(0).getParameter("Option_Inspection_available").setValue("true");
selectedEOs.get(0).getParameter("Option_Inspection_available").
setPrettyValue("=if existsRef('Library.Unit.Component')
then ref('Library.Unit.Component').$Option_Inspection_available else 'true' endif")