コード例 #1
0
 /** Builds the Identifier element of ConnectHome */
 private void buildIdentifierSection(EmaApiConnectHome alertFile) throws EmaException {
   EmaApiIdentifierType identifier = new EmaApiIdentifierType();
   EmaApiNode node = alertFile.getNode();
   identifier.setClarifyID(licenseInfo.getProductId());
   identifier.setDeviceType(_identifierManager.findDeviceType());
   identifier.setDeviceState(_identifierManager.findDeviceState());
   identifier.setModel(licenseInfo.getModelId());
   identifier.setOS(_identifierManager.findOS());
   identifier.setOSVER(_identifierManager.findOSVersion());
   identifier.setVendor("EMC");
   identifier.setSiteName("");
   identifier.setSerialNumber(licenseInfo.getProductId());
   identifier.setUcodeVer(_identifierManager.findPlatform());
   identifier.setWWN(licenseInfo.getLicenseTypeIndicator());
   node.setIdentifier(identifier);
   overrideIdentifierData(identifier);
 }
コード例 #2
0
  /**
   * Build the Device object using the controller license information.
   *
   * @param feature
   * @param device
   * @throws LocalRepositoryException
   */
  private void buildDevice(LicenseInfoExt licenseInfo, Device device)
      throws LocalRepositoryException {

    if (licenseInfo != null) {
      LocalRepository localRepository = LocalRepository.getInstance();
      // this is in the format of node1, node2, etc. We need to get the integer portion.
      String nodeId = _coordinator.getPropertyInfo().getProperties().get("node_id");
      String node;
      if (nodeId != null) {
        node = nodeId.substring(4);
      } else {
        node = CallHomeConstants.STANDALONE;
      }
      device.setSerialNumber(licenseInfo.getProductId() + "-" + node);
      device.setModelName(getBaseModelId(licenseInfo.getModelId()) + MODEL_NAME_SUFFIX);
      device.setIpAddress(_networkIpAddress);
    }
  }