1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * The contents of this file are subject to the terms of the Liferay Enterprise
5    * Subscription License ("License"). You may not use this file except in
6    * compliance with the License. You can obtain a copy of the License by
7    * contacting Liferay, Inc. See the License for the specific language governing
8    * permissions and limitations under the License, including but not limited to
9    * distribution rights of the Software.
10   *
11   *
12   * 
13   */
14  
15  package com.liferay.portlet.tags.service.impl;
16  
17  import com.liferay.portal.PortalException;
18  import com.liferay.portal.SystemException;
19  import com.liferay.portal.kernel.json.JSONArray;
20  import com.liferay.portlet.tags.model.TagsEntry;
21  import com.liferay.portlet.tags.service.base.TagsEntryServiceBaseImpl;
22  
23  import java.util.List;
24  
25  /**
26   * <a href="TagsEntryServiceImpl.java.html"><b><i>View Source</i></b></a>
27   *
28   * @author Brian Wing Shun Chan
29   */
30  public class TagsEntryServiceImpl extends TagsEntryServiceBaseImpl {
31  
32      public TagsEntry addEntry(String name)
33          throws PortalException, SystemException {
34  
35          return tagsEntryLocalService.addEntry(getUserId(), name);
36      }
37  
38      public TagsEntry addEntry(String name, String[] properties)
39          throws PortalException, SystemException {
40  
41          return tagsEntryLocalService.addEntry(getUserId(), name, properties);
42      }
43  
44      public void deleteEntry(long entryId)
45          throws PortalException, SystemException {
46  
47          tagsEntryLocalService.deleteEntry(entryId);
48      }
49  
50      public List<TagsEntry> getEntries(
51              long groupId, long companyId, long classNameId, String name)
52          throws SystemException {
53  
54          return tagsEntryLocalService.getEntries(
55              groupId, companyId, classNameId, name);
56      }
57  
58      public List<TagsEntry> getEntries(String className, long classPK)
59          throws SystemException {
60  
61          return tagsEntryLocalService.getEntries(className, classPK);
62      }
63  
64      public void mergeEntries(long fromEntryId, long toEntryId)
65          throws PortalException, SystemException {
66  
67          tagsEntryLocalService.mergeEntries(fromEntryId, toEntryId);
68      }
69  
70      public List<TagsEntry> search(
71              long companyId, String name, String[] properties)
72          throws SystemException {
73  
74          return tagsEntryLocalService.search(companyId, name, properties);
75      }
76  
77      public List<TagsEntry> search(
78          long companyId, String name, String[] properties, int start, int end)
79          throws SystemException {
80  
81          return tagsEntryLocalService.search(
82              companyId, name, properties, start, end);
83      }
84  
85      public JSONArray searchAutocomplete(
86              long companyId, String name, String[] properties, int start,
87              int end)
88          throws SystemException {
89  
90          return tagsEntryLocalService.searchAutocomplete(
91              companyId, name, properties, start, end);
92      }
93  
94      public int searchCount(long companyId, String name, String[] properties)
95          throws SystemException {
96  
97          return tagsEntryLocalService.searchCount(companyId, name, properties);
98      }
99  
100     public TagsEntry updateEntry(long entryId, String name)
101         throws PortalException, SystemException {
102 
103         return tagsEntryLocalService.updateEntry(entryId, name);
104     }
105 
106     public TagsEntry updateEntry(long entryId, String name, String[] properties)
107         throws PortalException, SystemException {
108 
109         return tagsEntryLocalService.updateEntry(
110             getUserId(), entryId, name, properties);
111     }
112 
113 }