public static com.liferay.knowledgebase.model.KBArticleSoap addKBArticle(
      java.lang.String portletId,
      long parentResourcePrimKey,
      java.lang.String title,
      java.lang.String content,
      java.lang.String description,
      java.lang.String[] sections,
      java.lang.String dirName,
      com.liferay.portal.service.ServiceContext serviceContext)
      throws RemoteException {
    try {
      com.liferay.knowledgebase.model.KBArticle returnValue =
          KBArticleServiceUtil.addKBArticle(
              portletId,
              parentResourcePrimKey,
              title,
              content,
              description,
              sections,
              dirName,
              serviceContext);

      return com.liferay.knowledgebase.model.KBArticleSoap.toSoapModel(returnValue);
    } catch (Exception e) {
      _log.error(e, e);

      throw new RemoteException(e.getMessage());
    }
  }
  public static com.liferay.knowledgebase.model.KBArticleSoap deleteKBArticle(long resourcePrimKey)
      throws RemoteException {
    try {
      com.liferay.knowledgebase.model.KBArticle returnValue =
          KBArticleServiceUtil.deleteKBArticle(resourcePrimKey);

      return com.liferay.knowledgebase.model.KBArticleSoap.toSoapModel(returnValue);
    } catch (Exception e) {
      _log.error(e, e);

      throw new RemoteException(e.getMessage());
    }
  }
  public static com.liferay.knowledgebase.model.KBArticleSoap[] getKBArticles(
      long groupId,
      long[] resourcePrimKeys,
      int status,
      com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
      throws RemoteException {
    try {
      java.util.List<com.liferay.knowledgebase.model.KBArticle> returnValue =
          KBArticleServiceUtil.getKBArticles(groupId, resourcePrimKeys, status, orderByComparator);

      return com.liferay.knowledgebase.model.KBArticleSoap.toSoapModels(returnValue);
    } catch (Exception e) {
      _log.error(e, e);

      throw new RemoteException(e.getMessage());
    }
  }
  public static KBArticleSoap toSoapModel(KBArticle model) {
    KBArticleSoap soapModel = new KBArticleSoap();

    soapModel.setUuid(model.getUuid());
    soapModel.setKbArticleId(model.getKbArticleId());
    soapModel.setResourcePrimKey(model.getResourcePrimKey());
    soapModel.setGroupId(model.getGroupId());
    soapModel.setCompanyId(model.getCompanyId());
    soapModel.setUserId(model.getUserId());
    soapModel.setUserName(model.getUserName());
    soapModel.setCreateDate(model.getCreateDate());
    soapModel.setModifiedDate(model.getModifiedDate());
    soapModel.setRootResourcePrimKey(model.getRootResourcePrimKey());
    soapModel.setParentResourceClassNameId(model.getParentResourceClassNameId());
    soapModel.setParentResourcePrimKey(model.getParentResourcePrimKey());
    soapModel.setKbFolderId(model.getKbFolderId());
    soapModel.setVersion(model.getVersion());
    soapModel.setTitle(model.getTitle());
    soapModel.setUrlTitle(model.getUrlTitle());
    soapModel.setContent(model.getContent());
    soapModel.setDescription(model.getDescription());
    soapModel.setPriority(model.getPriority());
    soapModel.setSections(model.getSections());
    soapModel.setViewCount(model.getViewCount());
    soapModel.setLatest(model.getLatest());
    soapModel.setMain(model.getMain());
    soapModel.setSourceURL(model.getSourceURL());
    soapModel.setLastPublishDate(model.getLastPublishDate());
    soapModel.setStatus(model.getStatus());
    soapModel.setStatusByUserId(model.getStatusByUserId());
    soapModel.setStatusByUserName(model.getStatusByUserName());
    soapModel.setStatusDate(model.getStatusDate());

    return soapModel;
  }