1 /*
2 * Copyright (C) 2003-2007 eXo Platform SAS.
3 *
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Affero General Public License
6 * as published by the Free Software Foundation; either version 3
7 * of the License, or (at your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, see<http://www.gnu.org/licenses/>.
16 */
17 package org.exoplatform.social.core.space.spi;
18
19 import org.exoplatform.commons.utils.ListAccess;
20 import org.exoplatform.social.core.application.PortletPreferenceRequiredPlugin;
21 import org.exoplatform.social.core.identity.model.Identity;
22 import org.exoplatform.social.core.space.SpaceApplicationConfigPlugin;
23 import org.exoplatform.social.core.space.SpaceException;
24 import org.exoplatform.social.core.space.SpaceFilter;
25 import org.exoplatform.social.core.space.SpaceListAccess;
26 import org.exoplatform.social.core.space.SpaceListenerPlugin;
27 import org.exoplatform.social.core.space.model.Space;
28
29 import java.util.List;
30
31 /**
32 * Provides methods to work with Space.
33 *
34 * @since Aug 29, 2008
35 *
36 */
37 public interface SpaceService {
38
39 /**
40 * Will be removed by 4.0.x.
41 */
42 @Deprecated
43 final String SPACES_APP_ID = "exosocial:spaces";
44
45 /**
46 * Gets a space by its display name.
47 *
48 * @param spaceDisplayName The space display name.
49 * @return The space.
50 * @LevelAPI Platform
51 * @since 1.2.0-GA
52 */
53 Space getSpaceByDisplayName(String spaceDisplayName);
54
55 /**
56 * Gets a space by its pretty name.
57 *
58 * @param spacePrettyName The space's pretty name.
59 * @return The space.
60 * @LevelAPI Platform
61 * @since 1.2.0-GA
62 */
63 Space getSpaceByPrettyName(String spacePrettyName);
64
65 /**
66 * Gets a space by its group Id.
67 *
68 * @param groupId The group Id.
69 * @return The space.
70 * @LevelAPI Platform
71 * @since 1.2.0-GA
72 */
73 Space getSpaceByGroupId(String groupId);
74
75 /**
76 * Gets a space by its Id.
77 *
78 * @param spaceId Id of the space.
79 * @return The space.
80 * @LevelAPI Platform
81 * @since 1.2.0-GA
82 */
83 Space getSpaceById(String spaceId);
84
85 /**
86 * Gets a space by its URL.
87 *
88 * @param spaceUrl URL of the space.
89 * @return The space.
90 * @LevelAPI Platform
91 * @since 1.2.0-GA
92 */
93 Space getSpaceByUrl(String spaceUrl);
94
95 /**
96 * Gets a list access that contains all spaces.
97 *
98 * @return The list access.
99 * @LevelAPI Platform
100 * @since 1.2.0-GA
101 */
102 ListAccess<Space> getAllSpacesWithListAccess();
103
104
105 /**
106 * Gets a list access that contains all spaces matching with a filter.
107 *
108 * @param spaceFilter The space filter.
109 * @return The list access.
110 * @LevelAPI Platform
111 * @since 1.2.0-GA
112 */
113 ListAccess<Space> getAllSpacesByFilter(SpaceFilter spaceFilter);
114
115 /**
116 * Gets a list access containing all spaces that a user has the "member" role.
117 *
118 * @param userId The remote user Id.
119 * @return The list access.
120 * @LevelAPI Platform
121 * @since 1.2.0-GA
122 */
123 ListAccess<Space> getMemberSpaces(String userId);
124
125 /**
126 * Gets a list access containing all spaces that a user has the "member" role. This list access matches with the provided space
127 * filter.
128 *
129 * @param userId The remote user Id.
130 * @param spaceFilter The space filter.
131 * @return The list access.
132 * @LevelAPI Platform
133 * @since 1.2.0-GA
134 */
135 ListAccess<Space> getMemberSpacesByFilter(String userId, SpaceFilter spaceFilter);
136
137 /**
138 * Gets a list access containing all spaces that a user has the access permission.
139 *
140 * @param userId The remote user Id.
141 * @return The space list access.
142 * @LevelAPI Platform
143 * @since 1.2.0-GA
144 */
145 ListAccess<Space> getAccessibleSpacesWithListAccess(String userId);
146
147 /**
148 * Gets a list access containing all spaces that a user has the access permission.
149 * This list access matches with the provided space filter.
150 *
151 * @param userId The remote user Id.
152 * @param spaceFilter The provided space filter.
153 * @return The list access.
154 * @LevelAPI Platform
155 * @since 1.2.0-GA
156 */
157 ListAccess<Space> getAccessibleSpacesByFilter(String userId, SpaceFilter spaceFilter);
158
159 /**
160 * Gets a list access containing all spaces that a user has the setting permission.
161 *
162 * @param userId The remote user Id.
163 * @return The space list access.
164 * @LevelAPI Platform
165 * @since 1.2.0-GA
166 */
167 ListAccess<Space> getSettingableSpaces(String userId);
168
169 /**
170 * Gets a list access containing all spaces that a user has the setting permission.
171 * This list access matches with the provided space filter.
172 *
173 * @param userId The remote user Id.
174 * @param spaceFilter The provided space filter.
175 * @return The space list access.
176 * @LevelAPI Platform
177 * @since 1.2.0-GA
178 */
179 ListAccess<Space> getSettingabledSpacesByFilter(String userId, SpaceFilter spaceFilter);
180
181 /**
182 * Gets a list access containing all spaces that a user is invited to join.
183 *
184 * @param userId The remote user Id.
185 * @return The list access.
186 * @LevelAPI Platform
187 * @since 1.2.0-GA
188 */
189 ListAccess<Space> getInvitedSpacesWithListAccess(String userId);
190
191 /**
192 * Gets a list access containing all spaces that a user is invited to join.
193 * This list access matches with the provided
194 * space filter.
195 *
196 * @param userId The remote user Id.
197 * @param spaceFilter The provided space filter.
198 * @return The list access.
199 * @LevelAPI Platform
200 * @since 1.2.0-GA
201 */
202 ListAccess<Space> getInvitedSpacesByFilter(String userId, SpaceFilter spaceFilter);
203
204 /**
205 * Gets a list access containing all spaces that a user can request to join.
206 *
207 * @param userId The remote user Id.
208 * @return The space list access.
209 * @LevelAPI Platform
210 * @since 1.2.0-GA
211 */
212 ListAccess<Space> getPublicSpacesWithListAccess(String userId);
213
214 /**
215 * Gets a list access containing all spaces that a user can request to join.
216 * This list access matches with the provided
217 * space filter.
218 *
219 * @param userId The remote user Id.
220 * @param spaceFilter The provided space filter.
221 * @return The list access.
222 * @LevelAPI Platform
223 * @since 1.2.0-GA
224 */
225 ListAccess<Space> getPublicSpacesByFilter(String userId, SpaceFilter spaceFilter);
226
227
228 /**
229 * Gets a list access containing all spaces that a user sent a request for joining a space.
230 *
231 * @param userId The remote user Id.
232 * @return The list access.
233 * @LevelAPI Platform
234 * @since 1.2.0-GA
235 */
236 ListAccess<Space> getPendingSpacesWithListAccess(String userId);
237
238 /**
239 * Gets a list access containing all spaces that a user sent a request for joining a space.
240 * This list access matches with the provided space filter.
241 *
242 * @param userId The remote user Id.
243 * @param spaceFilter The provided space filter.
244 * @return The list access.
245 * @LevelAPI Platform
246 * @since 1.2.0-GA
247 */
248 ListAccess<Space> getPendingSpacesByFilter(String userId, SpaceFilter spaceFilter);
249
250 /**
251 * Creates a new space: creating a group, its group navigation with pages for installing space applications.
252 *
253 * @param space The space to be created.
254 * @param creatorUserId The remote user Id.
255 * @return The created space.
256 * @LevelAPI Platform
257 */
258 Space createSpace(Space space, String creatorUserId);
259
260 /**
261 * Updates information of a space.
262 *
263 * @param existingSpace The existing space to be updated.
264 * @return The updated space.
265 * @LevelAPI Platform
266 * @since 1.2.0-GA
267 */
268 Space updateSpace(Space existingSpace);
269
270 /**
271 * Updates a space's avatar.
272 *
273 * @param existingSpace The existing space to be updated.
274 * @return The updated space.
275 * @LevelAPI Platform
276 * @since 1.2.0-GA
277 */
278 Space updateSpaceAvatar(Space existingSpace);
279
280 /**
281 * Updates a space's avatar.
282 *
283 * @param existingSpace The existing space to be updated.
284 * @return The updated space.
285 * @LevelAPI Platform
286 * @since 1.2.0-GA
287 */
288 Space updateSpaceBanner(Space existingSpace);
289
290 /**
291 * Deletes a space. When a space is deleted, all of its page navigations and its group will be deleted.
292 *
293 * @param space The space to be deleted.
294 * @LevelAPI Platform
295 */
296 void deleteSpace(Space space);
297
298 /**
299 * Adds a user to the list of pending requests for joining a space.
300 *
301 * @param space The exising space.
302 * @param userId The remote user Id.
303 * @LevelAPI Platform
304 * @since 1.2.0-GA
305 */
306 void addPendingUser(Space space, String userId);
307
308 /**
309 * Removes a user from a list of pending requests for joining a space.
310 *
311 * @param space The existing space.
312 * @param userId The remote user Id.
313 * @LevelAPI Platform
314 * @since 1.2.0-GA
315 */
316 void removePendingUser(Space space, String userId);
317
318 /**
319 * Checks if a user is in the list of pending requests for joining a space.
320 *
321 * @param space The existing space.
322 * @param userId The remote user Id.
323 * @return TRUE if the user request is pending. Otherwise, it is FALSE.
324 * @LevelAPI Platform
325 * @since 1.2.0-GA
326 *
327 */
328 boolean isPendingUser(Space space, String userId);
329
330 /**
331 * Adds a user to the list of users who are invited to join a space.
332 *
333 * @param space The existing space.
334 * @param userId The remote user Id.
335 * @LevelAPI Platform
336 * @since 1.2.0-GA
337 */
338 void addInvitedUser(Space space, String userId);
339
340 /**
341 * Removes a user from the list of users who are invited to join a space.
342 *
343 * @param space The existing space.
344 * @param userId The remote user Id.
345 * @LevelAPI Platform
346 * @since 1.2.0-GA
347 */
348 void removeInvitedUser(Space space, String userId);
349
350 /**
351 * Checks if a user is in the list of users who are invited to join a space.
352 *
353 * @param space The existing space.
354 * @param userId The remote user Id.
355 * @return TRUE if the user is in the list of invited users. Otherwise, it is FALSE.
356 * @LevelAPI Platform
357 * @since 1.2.0-GA
358 *
359 */
360 boolean isInvitedUser(Space space, String userId);
361
362 /**
363 * Adds a user to a space. The user will get the "member" role in a space.
364 *
365 * @param space The existing space.
366 * @param userId The remote user Id.
367 * @LevelAPI Platform
368 */
369 void addMember(Space space, String userId);
370
371 /**
372 * Removes a member from a space.
373 *
374 * @param space The existing space.
375 * @param userId The remote user Id.
376 * @LevelAPI Platform
377 */
378 void removeMember(Space space, String userId);
379
380 /**
381 * Checks if a given user is member of space or not.
382 *
383 * @param space The existing space.
384 * @param userId The remote user Id.
385 * @return TRUE if the user is member. Otherwise, it is FALSE.
386 * @LevelAPI Platform
387 */
388 boolean isMember(Space space, String userId);
389
390 /**
391 * Assigns the "manager" role to a user in a space.
392 *
393 * @param space The space that its user is assigned to manager.
394 * @param userId The remote user Id.
395 * @param isManager "True" if the user gets the "manager" role. "False" if the user only gets the "member" role.
396 * @LevelAPI Platform
397 * @since 1.2.0-GA
398 */
399 void setManager(Space space, String userId, boolean isManager);
400
401 /**
402 * Checks if a given user has the "manager" role in a space.
403 *
404 * @param space The space that its user is checked if he has the "manager" role or not.
405 * @param userId The remote user Id.
406 * @return "True" if the user has the "manager" role. Otherwise, it returns "false".
407 * @LevelAPI Platform
408 * @since 1.2.0-GA
409 */
410 boolean isManager(Space space, String userId);
411
412 /**
413 * Checks if a given user is the only one who has the "manager" role in a space.
414 *
415 * @param space The space that its user is checked if he is the only manager or not.
416 * @param userId The remote user Id.
417 * @return "True" if the user Id is the only one who has "manager" role in the space. Otherwise, it returns "false".
418 * @LevelAPI Platform
419 * @since 1.2.0-GA
420 */
421 boolean isOnlyManager(Space space, String userId);
422
423 /**
424 * Checks if a given user can access a space or not.
425 *
426 * @param space The space that its user is checked if he can access it.
427 * @param userId The remote user Id.
428 * @return "True" if the access permission is allowed. Otherwise, it returns "false".
429 * @LevelAPI Platform
430 *
431 */
432 boolean hasAccessPermission(Space space, String userId);
433
434 /**
435 * Checks if a given user has the setting permission to a space or not.
436 *
437 * @param space The space that its user is checked if he has the setting permission or not.
438 * @param userId The remote user Id.
439 * @return If the user is root or the space's member, "true" is returned. Otherwise, it returns "false".
440 * @LevelAPI Platform
441 * @since 1.2.0-GA
442 */
443 boolean hasSettingPermission(Space space, String userId);
444
445 /**
446 * Registers a space listener plugin to listen to space lifecyle events: creating, updating, installing an application, and more.
447 *
448 * @param spaceListenerPlugin The space listener plugin to be registered.
449 * @LevelAPI Platform
450 * @since 1.2.0-GA
451 */
452 void registerSpaceListenerPlugin(SpaceListenerPlugin spaceListenerPlugin);
453
454 /**
455 * Unregisters an existing space listener plugin.
456 *
457 * @param spaceListenerPlugin The space listener plugin to be unregistered.
458 * @LevelAPI Platform
459 * @since 1.2.0-GA
460 */
461 void unregisterSpaceListenerPlugin(SpaceListenerPlugin spaceListenerPlugin);
462
463 /**
464 * Sets a space application config plugin for configuring the home and space applications.
465 * <br>
466 * By configuring this, the space service will know how to create a new page node with title, URL and portlet.
467 *
468 * @param spaceApplicationConfigPlugin The space application config plugin to be set.
469 * @LevelAPI Platform
470 * @since 1.2.0-GA
471 */
472 @Deprecated
473 void setSpaceApplicationConfigPlugin(SpaceApplicationConfigPlugin spaceApplicationConfigPlugin);
474
475 /**
476 * Gets the space application config plugin.
477 *
478 * @return The space application config plugin.
479 * @LevelAPI Platform
480 */
481 @Deprecated
482 SpaceApplicationConfigPlugin getSpaceApplicationConfigPlugin();
483
484 /**
485 * Gets all spaces in Social.
486 *
487 * @return The list of spaces in Social.
488 * @throws SpaceException with code SpaceException.Code.ERROR_DATASTORE
489 * @LevelAPI Provisional
490 * @deprecated Use {@link #getAllSpacesWithListAccess()} instead.
491 * Will be removed by 4.0.x.
492 */
493 @Deprecated
494 List<Space> getAllSpaces() throws SpaceException;
495
496 /**
497 * Gets a space by its space name.
498 *
499 * @param spaceName The space name.
500 * @return The stored space.
501 * @throws SpaceException
502 * @LevelAPI Provisional
503 * @deprecated Use {@link SpaceService#getSpaceByPrettyName(String)} instead.
504 * Will be removed at 4.0.x.
505 */
506 public Space getSpaceByName(String spaceName) throws SpaceException;
507
508 /**
509 * Gets all spaces which have the name starting with the input character.
510 *
511 * @return All spaces in which their first characters match with the input string.
512 * @throws SpaceException with code SpaceException.Code.ERROR_DATASTORE
513 * @LevelAPI Provisional
514 * @deprecated Use {@link #getAllSpacesByFilter(org.exoplatform.social.core.space.SpaceFilter)} instead.
515 * Will be removed by 4.0.x.
516 */
517 @Deprecated
518 List<Space> getSpacesByFirstCharacterOfName(String firstCharacterOfName) throws SpaceException;
519
520 /**
521 * Gets all spaces that their names or descriptions match with the input condition.
522 *
523 * @param condition The input condition.
524 * @return The list of spaces.
525 * @throws Exception
526 * @LevelAPI Provisional
527 * @deprecated Use {@link #getAllSpacesByFilter(org.exoplatform.social.core.space.SpaceFilter)} instead.
528 * Will be removed by 4.0.x.
529 */
530 List<Space> getSpacesBySearchCondition(String condition) throws Exception;
531
532 /**
533 * Gets spaces that a given user is member.
534 *
535 * @param userId Id of the user.
536 * @return All spaces that the user is member.
537 * @throws SpaceException with code SpaceException.Code.ERROR_DATASTORE
538 * @LevelAPI Provisional
539 * @deprecated Use {@link #getMemberSpaces(String)} instead.
540 * Will be removed by 4.0.x.
541 */
542 @Deprecated
543 List<Space> getSpaces(String userId) throws SpaceException;
544
545 /**
546 * Gets spaces that a given user has the access permission.
547 *
548 * @param userId Id of the user.
549 * @return The list of spaces.
550 * @throws SpaceException
551 * @LevelAPI Provisional
552 * @deprecated Use {@link #getAccessibleSpacesWithListAccess(String)} instead.
553 * Will be removed by 4.0.x.
554 */
555 List<Space> getAccessibleSpaces(String userId) throws SpaceException;
556
557 /**
558 * Gets spaces that a given user can see.
559 *
560 * @param userId Id of the user.
561 * @param spaceFilter Condition by which spaces are filtered.
562 * @return The list of spaces.
563 * @throws SpaceException
564 * @LevelAPI Platform
565 * @since 1.2.5-GA
566 */
567 public List<Space> getVisibleSpaces(String userId, SpaceFilter spaceFilter) throws SpaceException;
568
569 /**
570 * Gets spaces that a given user can see.
571 * @param userId Id of the user.
572 * @param spaceFilter The condition by which spaces are filtered.
573 * @return The list of spaces.
574 * @LevelAPI Platform
575 * @since 1.2.5-GA
576 */
577 public SpaceListAccess getVisibleSpacesWithListAccess(String userId, SpaceFilter spaceFilter);
578
579 /**
580 * Provides the Unified Search feature to get spaces that a user can see.
581 * @param userId Id of the user.
582 * @param spaceFilter The condition by which spaces are filtered.
583 * @return The list of spaces.
584 * @LevelAPI Platform
585 * @since 4.0.0-GA
586 */
587 public SpaceListAccess getUnifiedSearchSpacesWithListAccess(String userId, SpaceFilter spaceFilter);
588
589 /**
590 * Gets spaces that a given user has the edit permission.
591 *
592 * @param userId Id of the user.
593 * @return The list of spaces.
594 * @throws SpaceException
595 * @LevelAPI Provisional
596 * @deprecated Use {@link #getSettingableSpaces(String)} instead.
597 * Will be removed by 4.0.x.
598 */
599 @Deprecated
600 List<Space> getEditableSpaces(String userId) throws SpaceException;
601
602 /**
603 * Gets all spaces that a given user is invited and can accept or deny requests.
604 *
605 * @param userId Id of the user.
606 * @return The list of spaces that the user is invited.
607 * @throws SpaceException
608 * @LevelAPI Provisional
609 * @deprecated Use {@link #getInvitedSpacesWithListAccess(String)} instead.
610 * Will be removed by 4.0.x.
611 */
612 @Deprecated
613 List<Space> getInvitedSpaces(String userId) throws SpaceException;
614
615
616 /**
617 * Gets public spaces which a given user can request to join.
618 *
619 * @param userId Id of the user.
620 * @return The list of spaces that the user can request to join.
621 * @throws SpaceException
622 * @LevelAPI Provisional
623 * @deprecated Use {@link #getPublicSpacesWithListAccess(String)} instead.
624 * Will be removed by 4.0.x.
625 */
626 @Deprecated
627 List<Space> getPublicSpaces(String userId) throws SpaceException;
628
629 /**
630 * Gets pending spaces which a given user can revoke requests.
631 *
632 * @param userId Id of the user.
633 * @return The list of pending spaces.
634 * @throws SpaceException
635 * @LevelAPI Provisional
636 * @deprecated Use {@link #getPendingSpacesWithListAccess(String)} instead.
637 * Will be removed by 4.0.x.
638 */
639 @Deprecated
640 List<Space> getPendingSpaces(String userId) throws SpaceException;
641
642 /**
643 * Creates a new space and invites all users from invitedGroupId to join this newly created space.
644 *
645 * @param space The space to be created.
646 * @param creator The user who creates the space.
647 * @param invitedGroupId Id of group who is invited to join the space.
648 * @return The space.
649 * @throws SpaceException with possible code SpaceException.Code.SPACE_ALREADY_EXIST; UNABLE_TO_ADD_CREATOR
650 * @LevelAPI Platform
651 * @deprecated Use {@link #createSpace(Space, String, List)} instead.
652 */
653 @Deprecated
654 Space createSpace(Space space, String creator, String invitedGroupId) throws SpaceException;
655
656 /**
657 * Creates a new space and invites all users from identitiesToInvite to join this newly created space.
658 *
659 * @param space The space to be created.
660 * @param creator The user who creates the space.
661 * @param identitiesToInvite The list of identities who are invited to join the space.
662 * Identity could be of type user or space
663 * @return The space.
664 * @throws SpaceException with possible code SpaceException.Code.SPACE_ALREADY_EXIST; UNABLE_TO_ADD_CREATOR
665 */
666 Space createSpace(Space space, String creator, List<Identity> identitiesToInvite) throws SpaceException;
667
668 /**
669 * Saves a new space or updates a space.
670 *
671 * @param space The space to be saved or updated.
672 * @param isNew "True" if a new space is created. "False" if an existing space is updated.
673 * @throws SpaceException with code: SpaceException.Code.ERROR_DATASTORE
674 * @LevelAPI Provisional
675 * @deprecated Use {@link #updateSpace(org.exoplatform.social.core.space.model.Space)} instead.
676 * Will be removed by 4.0.x.
677 */
678 void saveSpace(Space space, boolean isNew) throws SpaceException;
679
680 /**
681 * Renames a space.
682 *
683 * @param space The space to be renamed.
684 * @param newDisplayName New name of the space.
685 * @throws SpaceException
686 * @LevelAPI Platform
687 * @since 1.2.8
688 */
689 void renameSpace(Space space, String newDisplayName) throws SpaceException;
690
691 /**
692 * Renames a space by an identity who has rights of super admin.
693 *
694 * @param remoteId The identity who has renamed a space.
695 * @param space The space to be renamed.
696 * @param newDisplayName New name of the space.
697 * @throws SpaceException
698 * @LevelAPI Platform
699 * @since 4.0.0
700 */
701 void renameSpace(String remoteId, Space space, String newDisplayName) throws SpaceException;
702
703 /**
704 * Deletes a space by its Id.
705 *
706 * @param spaceId Id of the deleted space.
707 * @throws SpaceException
708 * @LevelAPI Provisional
709 * @deprecated Use {@link #deleteSpace(org.exoplatform.social.core.space.model.Space)} instead.
710 * Will be removed by 4.0.x.
711 */
712 @Deprecated
713 void deleteSpace(String spaceId) throws SpaceException;
714
715 /**
716 * Does nothing, just for compatible.
717 *
718 * @param space The space.
719 * @throws SpaceException with code SpaceException.Code.UNABLE_INIT_APP
720 * @LevelAPI Provisional
721 * @deprecated Will be removed by 4.0.x.
722 */
723 @Deprecated
724 void initApp(Space space) throws SpaceException;
725
726 /**
727 * Does nothing, just for compatible.
728 *
729 * @param space The space.
730 * @throws SpaceException with code SpaceException.Code.UNABLE_INIT_APP
731 * @LevelAPI Provisional
732 * @deprecated Will be removed by 4.0.x.
733 */
734 @Deprecated
735 void initApps(Space space) throws SpaceException;
736
737 /**
738 * Does nothing, just for compatible.
739 *
740 * @param space The space.
741 * @throws SpaceException
742 * @LevelAPI Provisional
743 * @deprecated Will be removed by 4.0.x.
744 */
745 @Deprecated
746 void deInitApps(Space space) throws SpaceException;
747
748 /**
749 * Adds a user to space as "member".
750 *
751 * @param spaceId Id of the space.
752 * @param userId Id of the user (remoteId).
753 * @throws SpaceException
754 * @LevelAPI Provisional
755 * @deprecated Use {@link #addMember(org.exoplatform.social.core.space.model.Space, String)} instead.
756 * Will be removed by 4.0.x.
757 */
758 @Deprecated
759 void addMember(String spaceId, String userId) throws SpaceException;
760
761 /**
762 * Removes a member from space.
763 *
764 * @param spaceId Id of the space.
765 * @param userId Id of the user (remoteId).
766 * @throws SpaceException
767 * @LevelAPI Provisional
768 * @deprecated Use {@link #removeMember(org.exoplatform.social.core.space.model.Space, String)} instead.
769 * Will be removed by 4.0.x.
770 */
771 @Deprecated
772 void removeMember(String spaceId, String userId) throws SpaceException;
773
774 /**
775 * Gets a list of members from a given space.
776 *
777 * @param space The space.
778 * @return The list of space members.
779 * @throws SpaceException
780 * @LevelAPI Provisional
781 * @deprecated Use {@link Space#getMembers()} instead.
782 * Will be removed by 4.0.x.
783 */
784 @Deprecated
785 List<String> getMembers(Space space) throws SpaceException;
786
787 /**
788 * Gets a list of members from a given space.
789 *
790 * @param spaceId Id of the space.
791 * @return The list of space members.
792 * @throws SpaceException
793 * @LevelAPI Provisional
794 * @deprecated Use {@link Space#getMembers()} instead.
795 * Will be removed by 4.0.x.
796 */
797 @Deprecated
798 List<String> getMembers(String spaceId) throws SpaceException;
799
800 /**
801 * Sets a space member to manager or vice versa.
802 *
803 * @param space The space.
804 * @param userId Id of the user (remoteId).
805 * @param isLeader If "true", the space member is set to manager. If "false", the space manager is set to member.
806 * @throws SpaceException
807 * @LevelAPI Provisional
808 * @deprecated Use {@link #setManager(org.exoplatform.social.core.space.model.Space, String, boolean)} instead.
809 * Will be removed by 4.0.x.
810 */
811 @Deprecated
812 void setLeader(Space space, String userId, boolean isLeader) throws SpaceException;
813
814 /**
815 * Sets a space member to manager or vice versa.
816 *
817 * @param spaceId Id of the space.
818 * @param userId Id of the user (remoteId).
819 * @param isLeader If "true", the space member is set to manager. If "false", the space manager is set to member.
820 * @throws SpaceException
821 * @LevelAPI Provisional
822 * @deprecated Use {@link #setManager(org.exoplatform.social.core.space.model.Space, String, boolean)} instead.
823 * Will be removed by 4.0.x.
824 */
825 @Deprecated
826 void setLeader(String spaceId, String userId, boolean isLeader) throws SpaceException;
827
828 /**
829 * Checks if a given user is space manager or not.
830 *
831 * @param space The space.
832 * @param userId Id of the user (remoteId).
833 * @return "True" if the user is space manager. Otherwise, it returns "false".
834 * @throws SpaceException
835 * @LevelAPI Provisional
836 * @deprecated Use {@link #isManager(org.exoplatform.social.core.space.model.Space, String)} instead.
837 * Will be removed by 4.0.x.
838 */
839 @Deprecated
840 boolean isLeader(Space space, String userId) throws SpaceException;
841
842 /**
843 * Checks if a given user is space manager or not.
844 *
845 * @param spaceId Id of the space.
846 * @param userId Id of the user (remoteId).
847 * @return "True" if the user is space manager. Otherwise, it returns "false".
848 * @throws SpaceException
849 * @LevelAPI Provisional
850 * @deprecated Use {@link #isManager(org.exoplatform.social.core.space.model.Space, String)} instead.
851 * Will be removed by 4.0.x.
852 */
853 @Deprecated
854 boolean isLeader(String spaceId, String userId) throws SpaceException;
855
856 /**
857 * Checks if a given user is the only manager of space or not.
858 *
859 * @param space The space.
860 * @param userId Id of the user (remoteId).
861 * @return "True" if the user is the only space manager. Otherwise, it returns "false".
862 * @throws SpaceException
863 * @LevelAPI Provisional
864 * @deprecated Use {@link #isOnlyManager(org.exoplatform.social.core.space.model.Space, String)} instead.
865 * Will be removed by 4.0.x.
866 */
867 @Deprecated
868 boolean isOnlyLeader(Space space, String userId) throws SpaceException;
869
870 /**
871 * Checks if a given user is the only manager of space or not.
872 *
873 * @param spaceId Id of the space.
874 * @param userId Id of the user (remoteId).
875 * @return "True" if the user is the only space manager. Otherwise, it returns "false".
876 * @throws SpaceException
877 * @LevelAPI Provisional
878 * @deprecated Use {@link #isOnlyManager(org.exoplatform.social.core.space.model.Space, String)} instead.
879 * Will be removed by 4.0.x.
880 */
881 @Deprecated
882 boolean isOnlyLeader(String spaceId, String userId) throws SpaceException;
883
884 /**
885 * Checks if a given user is space member or not.
886 *
887 * @param spaceId Id of the space.
888 * @param userId Id of user (remoteId).
889 * @return "True" if the user is space member. Otherwise, it returns "false".
890 * @throws SpaceException
891 * @LevelAPI Provisional
892 * @deprecated Use {@link #isMember(org.exoplatform.social.core.space.model.Space, String)} instead.
893 * Will be removed by 4.0.x.
894 */
895 @Deprecated
896 boolean isMember(String spaceId, String userId) throws SpaceException;
897
898 /**
899 * Checks if a user can access a space or not.
900 * If the user is root or the space's member, the "true" value is returned.
901 *
902 * @param spaceId Id of the space.
903 * @param userId Id of the user (remoteId).
904 * @return "True" if the user has the access permission. "False" if the user does not have the access permission.
905 * @throws SpaceException
906 * @LevelAPI Provisional
907 * @deprecated Use {@link #hasAccessPermission(org.exoplatform.social.core.space.model.Space, String)} instead.
908 * Will be removed by 4.0.x.
909 */
910 @Deprecated
911 boolean hasAccessPermission(String spaceId, String userId) throws SpaceException;
912
913 /**
914 * Checks if a user has the edit permission on a space or not.
915 * If the user is root or the space's manager, "true" is returned.
916 *
917 * @param space The provided space.
918 * @param userId Id of the user (remoteId).
919 * @return "True" if the user has the edit permission. "False" if the user does not have the edit permission.
920 * @throws SpaceException
921 * @LevelAPI Provisional
922 * @deprecated Use {@link #hasSettingPermission(org.exoplatform.social.core.space.model.Space, String)} instead.
923 * Will be removed by 4.0.x.
924 */
925 @Deprecated
926 boolean hasEditPermission(Space space, String userId) throws SpaceException;
927
928 /**
929 * Checks if a user has the edit permission on a space.
930 * If user is root or the space's manager, "true" is returned.
931 * @param spaceId Id of the space.
932 * @param userId Id of the user (remoteId).
933 * @return "True" if the user has the edit permission. "False" if the user does not have the edit permission.
934 * @throws SpaceException
935 * @LevelAPI Provisional
936 * @deprecated Use {@link #hasSettingPermission(org.exoplatform.social.core.space.model.Space, String)} instead.
937 * Will be removed by 4.0.x.
938 */
939 @Deprecated
940 boolean hasEditPermission(String spaceId, String userId) throws SpaceException;
941
942 /**
943 * Checks if a user is in the list of invited users of a space.
944 *
945 * @param space The provided space.
946 * @param userId Id of the user (remoteId).
947 * @return "True" if the user is in the list of invited users. Otherwise, it returns "false".
948 * @throws SpaceException
949 * @LevelAPI Provisional
950 * @deprecated Use {@link #isInvitedUser(org.exoplatform.social.core.space.model.Space, String)} instead.
951 * Will be removed by 4.0.x.
952 */
953 @Deprecated
954 boolean isInvited(Space space, String userId) throws SpaceException;
955
956 /**
957 * Checks if a user is in the list of invited users of a space.
958 *
959 * @param spaceId Id of the space.
960 * @param userId Id of the user (remoteId).
961 * @return "True" if the user is in the list of invited users. Otherwise, it returns "false".
962 * @throws SpaceException
963 * @LevelAPI Provisional
964 * @deprecated Use {@link #isInvitedUser(org.exoplatform.social.core.space.model.Space, String)} instead.
965 * Will be removed by 4.0.x.
966 */
967 @Deprecated
968 boolean isInvited(String spaceId, String userId) throws SpaceException;
969
970 /**
971 * Checks if a user is in the list of pending users of a space or not.
972 *
973 * @param space The space.
974 * @param userId Id of the user (remoteId).
975 * @return "True" if the user is in the list of pending users. Otherwise, it returns "false".
976 * @throws SpaceException
977 * @LevelAPI Provisional
978 * @deprecated Use {@link #isPendingUser(org.exoplatform.social.core.space.model.Space, String)} instead.
979 * Will be removed by 4.0.x.
980 */
981 @Deprecated
982 boolean isPending(Space space, String userId) throws SpaceException;
983
984 /**
985 * Checks if a user is in the list of pending users of a space.
986 *
987 * @param spaceId Id of the user.
988 * @param userId Id of the user (remoteId).
989 * @return "True" if the user is in the list of pending users. Otherwise, it returns "false".
990 * @throws SpaceException
991 * @LevelAPI Provisional
992 * @deprecated Use {@link #isPendingUser(org.exoplatform.social.core.space.model.Space, String)} instead.
993 * Will be removed by 4.0.x.
994 */
995 @Deprecated
996 boolean isPending(String spaceId, String userId) throws SpaceException;
997
998 /**
999 * Checks if a user is in the list of users who have ignored the space.
1000 *
1001 * @param space The existing space.
1002 * @param userId The remote user Id.
1003 * @return TRUE if the space is an ignored space. Otherwise, it
1004 * is FALSE.
1005 */
1006 default boolean isIgnored(Space space, String userId) {
1007 return false;
1008 }
1009
1010 /**
1011 * Assigns the user who has ignored the space.
1012 *
1013 * @param spaceId The Id of the space ignored by the user.
1014 * @param userId The remote user Id.
1015 */
1016 default void setIgnored(String spaceId, String userId) {
1017
1018 }
1019
1020 /**
1021 * Installs an application in a space.
1022 *
1023 * @param spaceId Id of the space that the application is installed.
1024 * @param appId Id of the application which is installed.
1025 * @throws SpaceException with code SpaceException.Code.ERROR_DATA_STORE
1026 * @LevelAPI Platform
1027 */
1028 void installApplication(String spaceId, String appId) throws SpaceException;
1029
1030 /**
1031 * Installs an application in a space.
1032 *
1033 * @param space The space that the application is installed.
1034 * @param appId Id of the installed application.
1035 * @throws SpaceException with code SpaceException.Code.ERROR_DATA_STORE
1036 * @LevelAPI Platform
1037 */
1038 void installApplication(Space space, String appId) throws SpaceException;
1039
1040 /**
1041 * Activates an installed application in a space.
1042 *
1043 * @param space The space that the installed application is activated.
1044 * @param appId Id of the installed application.
1045 * @throws SpaceException with possible code: SpaceException.Code.UNABLE_TO_ADD_APPLICATION,
1046 * SpaceExeption.Code.ERROR_DATA_STORE
1047 * @LevelAPI Platform
1048 */
1049 void activateApplication(Space space, String appId) throws SpaceException;
1050
1051 /**
1052 * Activates an installed application in a space.
1053 *
1054 * @param spaceId Id of the space that the installed application is activated.
1055 * @param appId Id of the installed application.
1056 * @throws SpaceException with possible code: SpaceException.Code.UNABLE_TO_ADD_APPLICATION,
1057 * SpaceExeption.Code.ERROR_DATA_STORE
1058 * @LevelAPI Platform
1059 */
1060 void activateApplication(String spaceId, String appId) throws SpaceException;
1061
1062 /**
1063 * Deactivates an installed application in a space.
1064 *
1065 * @param space The space that the installed application is deactivated.
1066 * @param appId Id of the installed application.
1067 * @throws SpaceException
1068 * @LevelAPI Platform
1069 */
1070 void deactivateApplication(Space space, String appId) throws SpaceException;
1071
1072 /**
1073 * Deactivates an installed application in a space.
1074 *
1075 * @param spaceId Id of the space that the installed application is deactivated.
1076 * @param appId Id of the installed application.
1077 * @throws SpaceException
1078 * @LevelAPI Platform
1079 */
1080 void deactivateApplication(String spaceId, String appId) throws SpaceException;
1081
1082 /**
1083 * Removes an installed application from a space.
1084 *
1085 * @param space The space that the installed application is removed.
1086 * @param appId Id of the installed application.
1087 * @throws SpaceException
1088 * @LevelAPI Platform
1089 */
1090 void removeApplication(Space space, String appId, String appName) throws SpaceException;
1091
1092 /**
1093 * Removes an installed application from a space.
1094 *
1095 * @param spaceId Id of the space that the installed application is removed.
1096 * @param appId Id of the installed application.
1097 * @LevelAPI Platform
1098 */
1099 void removeApplication(String spaceId, String appId, String appName) throws SpaceException;
1100
1101 /**
1102 * Updates the most recently accessed space of a user to the top of spaces list.
1103 *
1104 * @param remoteId The remote Id of the user.
1105 * @param space The last accessed space of the user.
1106 * @LevelAPI Platform
1107 */
1108 void updateSpaceAccessed(String remoteId, Space space) throws SpaceException;
1109
1110 /**
1111 * Gets a list of the most recently accessed spaces of a user.
1112 *
1113 * @param remoteId The remote Id of user.
1114 * @param appId Id of the installed application in a space.
1115 * @param offset The starting point to get the most recently accessed spaces.
1116 * @param limit The limitation of the most recently accessed spaces.
1117 * @LevelAPI Platform
1118 */
1119 List<Space> getLastAccessedSpace(String remoteId, String appId, int offset, int limit) throws SpaceException;
1120
1121 /**
1122 * Gets the last spaces that have been created.
1123 *
1124 * @param limit the limit of spaces to provide.
1125 * @return The last spaces.
1126 * @LevelAPI Experimental
1127 * @since 4.0.x
1128 */
1129 List<Space> getLastSpaces(int limit);
1130
1131 /**
1132 * Gets a list of the most recently accessed spaces of a user.
1133 *
1134 * @param remoteId The remote Id of a user.
1135 * @param appId Id of the installed application in a space.
1136 * @LevelAPI Platform
1137 */
1138 ListAccess<Space> getLastAccessedSpace(String remoteId, String appId);
1139
1140
1141 /**
1142 * Requests to join a space, then adds the requester to the list of pending spaces.
1143 *
1144 * @param space The space which the user requests to join.
1145 * @param userId Id of the user (remoteId).
1146 * @throws SpaceException
1147 * @LevelAPI Provisional
1148 * @deprecated Use {@link #addPendingUser(org.exoplatform.social.core.space.model.Space, String)} instead.
1149 * Will be removed by 4.0.x.
1150 */
1151 @Deprecated
1152 void requestJoin(Space space, String userId) throws SpaceException;
1153
1154 /**
1155 * Requests to join a space, then adds the requester to the list of pending spaces.
1156 *
1157 * @param spaceId Id of the space.
1158 * @param userId Id of the user (remoteId).
1159 * @throws SpaceException
1160 * @LevelAPI Provisional
1161 * @deprecated Use {@link #addPendingUser(org.exoplatform.social.core.space.model.Space, String)} instead.
1162 * Will be removed by 4.0.x.
1163 */
1164 @Deprecated
1165 void requestJoin(String spaceId, String userId) throws SpaceException;
1166
1167 /**
1168 * Revokes a request to join a space.
1169 *
1170 * @param space The space which the user requests to join.
1171 * @param userId Id of the user (remoteId).
1172 * @throws SpaceException
1173 * @LevelAPI Provisional
1174 * @deprecated Use {@link #removePendingUser(org.exoplatform.social.core.space.model.Space, String)} instead.
1175 * Will be removed by 4.0.x.
1176 */
1177 @Deprecated
1178 void revokeRequestJoin(Space space, String userId) throws SpaceException;
1179
1180 /**
1181 * Revokes a request to join a space.
1182 *
1183 * @param spaceId Id of the space.
1184 * @param userId Id of the user.
1185 * @throws SpaceException
1186 * @LevelAPI Provisional
1187 * @deprecated Use {@link #removePendingUser(org.exoplatform.social.core.space.model.Space, String)} instead.
1188 * Will be removed by 4.0.x.
1189 */
1190 @Deprecated
1191 void revokeRequestJoin(String spaceId, String userId) throws SpaceException;
1192
1193 /**
1194 * Invites a user to become a space member.
1195 *
1196 * @param space The space.
1197 * @param userId Id of the user (remoteId).
1198 * @throws SpaceException
1199 * @LevelAPI Provisional
1200 * @deprecated Use {@link #addInvitedUser(org.exoplatform.social.core.space.model.Space, String)} instead.
1201 * Will be removed by 4.0.x.
1202 */
1203 @Deprecated
1204 void inviteMember(Space space, String userId) throws SpaceException;
1205
1206 /**
1207 * Invites a user to become a space member.
1208 *
1209 * @param spaceId Id of the space.
1210 * @param userId Id of the user (remoteId).
1211 * @throws SpaceException
1212 * @LevelAPI Provisional
1213 * @deprecated Use {@link #addInvitedUser(org.exoplatform.social.core.space.model.Space, String)} instead.
1214 * Will be removed by 4.0.x.
1215 */
1216 @Deprecated
1217 void inviteMember(String spaceId, String userId) throws SpaceException;
1218
1219 /**
1220 * Revokes an invitation - Removes the user from the list of invited users of the space.
1221 *
1222 * @param space The space.
1223 * @param userId Id of the user (remoteId).
1224 * @throws SpaceException
1225 * @LevelAPI Provisional
1226 * @deprecated Use {@link #removeInvitedUser(org.exoplatform.social.core.space.model.Space, String)} instead.
1227 * Will be removed by 4.0.x.
1228 */
1229 @Deprecated
1230 void revokeInvitation(Space space, String userId) throws SpaceException;
1231
1232 /**
1233 * Revokes an invitation - Removes the user from the list of invited users of the space.
1234 *
1235 * @param spaceId Id of the space.
1236 * @param userId Id of the user (remoteId).
1237 * @throws SpaceException
1238 * @LevelAPI Provisional
1239 * @deprecated Use {@link #removeInvitedUser(org.exoplatform.social.core.space.model.Space, String)} instead.
1240 * Will be removed by 4.0.x.
1241 */
1242 @Deprecated
1243 void revokeInvitation(String spaceId, String userId) throws SpaceException;
1244
1245 /**
1246 * Accepts an invitation - Moves the user from the invited users list to the members list.
1247 *
1248 * @param space The space.
1249 * @param userId Id of the user (remoteId).
1250 * @throws SpaceException
1251 * @LevelAPI Provisional
1252 * @deprecated Use {@link #addMember(org.exoplatform.social.core.space.model.Space, String)} instead.
1253 * Will be removed by 4.0.x.
1254 */
1255 @Deprecated
1256 void acceptInvitation(Space space, String userId) throws SpaceException;
1257
1258 /**
1259 * Accepts an invitation - Moves the user from the invited users list to the members list.
1260 *
1261 * @param spaceId Id of the space.
1262 * @param userId Id of the user (remoteId).
1263 * @throws SpaceException
1264 * @LevelAPI Provisional
1265 * @deprecated Use {@link #addMember(org.exoplatform.social.core.space.model.Space, String)} instead.
1266 * Will be removed by 4.0.x.
1267 */
1268 @Deprecated
1269 void acceptInvitation(String spaceId, String userId) throws SpaceException;
1270
1271 /**
1272 * Denies an invitation - Removes the user from the list of invited users.
1273 *
1274 * @param space The space.
1275 * @param userId Id of the user (remoteId).
1276 * @throws SpaceException
1277 * @LevelAPI Provisional
1278 * @deprecated Use {@link #removeInvitedUser(org.exoplatform.social.core.space.model.Space, String)} instead.
1279 * Will be removed by 4.0.x.
1280 */
1281 @Deprecated
1282 void denyInvitation(Space space, String userId) throws SpaceException;
1283
1284 /**
1285 * Denies an invitation - Removes the user from the list of invited users.
1286 *
1287 * @param spaceId Id of the space.
1288 * @param userId Id of the user (remoteId).
1289 * @throws SpaceException
1290 * @LevelAPI Provisional
1291 * @deprecated Use {@link #removeInvitedUser(org.exoplatform.social.core.space.model.Space, String)} instead.
1292 * Will be removed by 4.0.x.
1293 */
1294 @Deprecated
1295 void denyInvitation(String spaceId, String userId) throws SpaceException;
1296
1297 /**
1298 * Validates a request - Moves the user from the pending users list to the members list.
1299 *
1300 * @param space The space.
1301 * @param userId Id of the user (remoteId).
1302 * @throws SpaceException
1303 * @LevelAPI Provisional
1304 * @deprecated Use {@link #addMember(org.exoplatform.social.core.space.model.Space, String)} instead.
1305 * Will be removed by 4.0.x.
1306 */
1307 @Deprecated
1308 void validateRequest(Space space, String userId) throws SpaceException;
1309
1310 /**
1311 * Validates a request - Moves the user from the pending users list to the members list.
1312 *
1313 * @param spaceId Id of the space.
1314 * @param userId Id of the user (remoteId).
1315 * @throws SpaceException
1316 * @LevelAPI Provisional
1317 * @deprecated Use {@link #addMember(org.exoplatform.social.core.space.model.Space, String)} instead.
1318 * Will be removed by 4.0.x.
1319 */
1320 @Deprecated
1321 void validateRequest(String spaceId, String userId) throws SpaceException;
1322
1323 /**
1324 * Declines a request - Removes the user from the pending users list.
1325 *
1326 * @param space The space.
1327 * @param userId Id of the user (remoteId).
1328 * @throws SpaceException
1329 * @LevelAPI Provisional
1330 * @deprecated Use {@link #removePendingUser(org.exoplatform.social.core.space.model.Space, String)} instead.
1331 * Will be removed by 4.0.x.
1332 */
1333 @Deprecated
1334 void declineRequest(Space space, String userId) throws SpaceException;
1335
1336 /**
1337 * Declines a request - Removes the user from the pending users list.
1338 *
1339 * @param spaceId Id of the space.
1340 * @param userId Id of the user (remoteId).
1341 * @throws SpaceException
1342 * @LevelAPI Provisional
1343 * @deprecated Use {@link #removePendingUser(org.exoplatform.social.core.space.model.Space, String)} instead.
1344 * Will be removed by 4.0.x.
1345 */
1346 @Deprecated
1347 void declineRequest(String spaceId, String userId) throws SpaceException;
1348
1349 /**
1350 * Registers a space lifecycle listener.
1351 *
1352 * @param listener The space lifecycle listener to be registered.
1353 * @LevelAPI Provisional
1354 * @deprecated Will be removed by 4.0.x.
1355 */
1356 @Deprecated
1357 void registerSpaceLifeCycleListener(SpaceLifeCycleListener listener);
1358
1359 /**
1360 * Unregisters a space lifecycle listener.
1361 *
1362 * @param listener The space lifecycle listener to be unregistered.
1363 * @LevelAPI Provisional
1364 * @deprecated Will be removed by 4.0.x.
1365 */
1366 @Deprecated
1367 void unregisterSpaceLifeCycleListener(SpaceLifeCycleListener listener);
1368
1369 /**
1370 * Sets the portlet preferences got from the plugin configuration.
1371 *
1372 *
1373 * @param portletPrefsRequiredPlugin The plugin that configures portlets to store spaceUrl in its portlet-preference.
1374 * @LevelAPI Provisional
1375 * @deprecated Use {@link SpaceApplicationConfigPlugin} instead.
1376 * Will be removed by 4.0.x.
1377 */
1378 @Deprecated
1379 void setPortletsPrefsRequired(PortletPreferenceRequiredPlugin portletPrefsRequiredPlugin);
1380 /**
1381 * Gets the portlet preferences which are required for creating the portlet application.
1382 *
1383 * @return Array of the portlet preferences.
1384 * @LevelAPI Provisional
1385 * @deprecated Will be removed by 4.0.x.
1386 */
1387 String [] getPortletsPrefsRequired();
1388
1389 /**
1390 * Gets the list of spaces which are visited by users
1391 *
1392 * @param remoteId
1393 * @param appId
1394 * @return
1395 */
1396 ListAccess<Space> getVisitedSpaces(String remoteId, String appId);
1397
1398 /**
1399 * Checks if the user is a super manager of all spaces
1400 *
1401 * @param userId username
1402 * @return true if the user is member of super administrators groups, else false
1403 */
1404 boolean isSuperManager(String userId);
1405
1406 }