void checkType(PortReader& reader) { if (!checkedType) { if (!typ.isValid()) { typ = reader.getReadType(); } checkedType = true; } }