code: public void encodeData(AsnOutputStream asnOs) throws MAPException {
          if (this.callSessionUnrelated == null) {
              throw new MAPException(
                      "Error while encoding LCSPrivacyCheck the mandatory parameter callSessionUnrelated is not defined");
          }
  
          try {
              asnOs.writeInteger(Tag.CLASS_CONTEXT_SPECIFIC, _TAG_CALL_SESSION_UNRELATED, this.callSessionUnrelated.getAction());
          } catch (IOException e) {
              throw new MAPException("IOException when encoding parameter LCSPrivacyCheck.callSessionUnrelated", e);
          } catch (AsnException e) {
              throw new MAPException("AsnException when encoding parameter LCSPrivacyCheck.callSessionUnrelated", e);
          }
  
          if (this.callSessionRelated != null) {
              try {
                  asnOs.writeInteger(Tag.CLASS_CONTEXT_SPECIFIC, _TAG_CALL_SESSION_RELATED, this.callSessionRelated.getAction());
              } catch (IOException e) {
                  throw new MAPException("IOException when encoding parameter LCSPrivacyCheck.callSessionRelated", e);
              } catch (AsnException e) {
                  throw new MAPException("AsnException when encoding parameter LCSPrivacyCheck.callSessionRelated", e);
              }
          }
      }
docs: /*
  (non-Javadoc)
  
  @see org.restcomm.protocols.ss7.map.api.primitives.MAPAsnPrimitive#encodeData
  (org.mobicents.protocols.asn.AsnOutputStream)