001 /** 002 * Copyright (c) 2000-present Liferay, Inc. All rights reserved. 003 * 004 * This library is free software; you can redistribute it and/or modify it under 005 * the terms of the GNU Lesser General Public License as published by the Free 006 * Software Foundation; either version 2.1 of the License, or (at your option) 007 * any later version. 008 * 009 * This library is distributed in the hope that it will be useful, but WITHOUT 010 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 011 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more 012 * details. 013 */ 014 015 package com.liferay.portlet.dynamicdatamapping.service; 016 017 import aQute.bnd.annotation.ProviderType; 018 019 import com.liferay.portal.kernel.exception.PortalException; 020 import com.liferay.portal.kernel.exception.SystemException; 021 import com.liferay.portal.kernel.search.IndexableType; 022 import com.liferay.portal.kernel.transaction.Isolation; 023 import com.liferay.portal.kernel.transaction.Propagation; 024 import com.liferay.portal.kernel.transaction.Transactional; 025 import com.liferay.portal.model.SystemEventConstants; 026 import com.liferay.portal.service.BaseLocalService; 027 import com.liferay.portal.service.PersistedModelLocalService; 028 029 /** 030 * Provides the local service interface for DDMStructure. Methods of this 031 * service will not have security checks based on the propagated JAAS 032 * credentials because this service can only be accessed from within the same 033 * VM. 034 * 035 * @author Brian Wing Shun Chan 036 * @see DDMStructureLocalServiceUtil 037 * @see com.liferay.portlet.dynamicdatamapping.service.base.DDMStructureLocalServiceBaseImpl 038 * @see com.liferay.portlet.dynamicdatamapping.service.impl.DDMStructureLocalServiceImpl 039 * @generated 040 */ 041 @ProviderType 042 @Transactional(isolation = Isolation.PORTAL, rollbackFor = { 043 PortalException.class, SystemException.class}) 044 public interface DDMStructureLocalService extends BaseLocalService, 045 PersistedModelLocalService { 046 /* 047 * NOTE FOR DEVELOPERS: 048 * 049 * Never modify or reference this interface directly. Always use {@link DDMStructureLocalServiceUtil} to access the d d m structure local service. Add custom service methods to {@link com.liferay.portlet.dynamicdatamapping.service.impl.DDMStructureLocalServiceImpl} and rerun ServiceBuilder to automatically copy the method declarations to this interface. 050 */ 051 052 /** 053 * Adds the d d m structure to the database. Also notifies the appropriate model listeners. 054 * 055 * @param ddmStructure the d d m structure 056 * @return the d d m structure that was added 057 */ 058 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 059 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure addDDMStructure( 060 com.liferay.portlet.dynamicdatamapping.model.DDMStructure ddmStructure); 061 062 public void addDLFileEntryTypeDDMStructure(long fileEntryTypeId, 063 com.liferay.portlet.dynamicdatamapping.model.DDMStructure ddmStructure); 064 065 public void addDLFileEntryTypeDDMStructure(long fileEntryTypeId, 066 long structureId); 067 068 public void addDLFileEntryTypeDDMStructures(long fileEntryTypeId, 069 java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> DDMStructures); 070 071 public void addDLFileEntryTypeDDMStructures(long fileEntryTypeId, 072 long[] structureIds); 073 074 public void addJournalFolderDDMStructure(long folderId, 075 com.liferay.portlet.dynamicdatamapping.model.DDMStructure ddmStructure); 076 077 public void addJournalFolderDDMStructure(long folderId, long structureId); 078 079 public void addJournalFolderDDMStructures(long folderId, 080 java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> DDMStructures); 081 082 public void addJournalFolderDDMStructures(long folderId, long[] structureIds); 083 084 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure addStructure( 085 long userId, long groupId, long classNameId, 086 java.util.Map<java.util.Locale, java.lang.String> nameMap, 087 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 088 com.liferay.portlet.dynamicdatamapping.model.DDMForm ddmForm, 089 com.liferay.portal.service.ServiceContext serviceContext) 090 throws com.liferay.portal.kernel.exception.PortalException; 091 092 /** 093 * Adds a structure referencing a default parent structure, using the portal 094 * property <code>dynamic.data.lists.storage.type</code> storage type and 095 * default structure type. 096 * 097 * @param userId the primary key of the structure's creator/owner 098 * @param groupId the primary key of the group 099 * @param classNameId the primary key of the class name for the 100 structure's related model 101 * @param nameMap the structure's locales and localized names 102 * @param descriptionMap the structure's locales and localized 103 descriptions 104 * @param definition the structure's XML schema definition 105 * @param serviceContext the service context to be applied. Can set the 106 UUID, creation date, modification date, guest permissions, 107 and group permissions for the structure. 108 * @return the structure 109 * @throws PortalException if a user with the primary key could not be 110 found, if the XSD was not well-formed, or if a portal 111 exception occurred 112 * @deprecated As of 7.0.0, replaced by {@link #addStructure(long, long, 113 long, Map, Map, DDMForm, ServiceContext)} 114 */ 115 @java.lang.Deprecated 116 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure addStructure( 117 long userId, long groupId, long classNameId, 118 java.util.Map<java.util.Locale, java.lang.String> nameMap, 119 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 120 java.lang.String definition, 121 com.liferay.portal.service.ServiceContext serviceContext) 122 throws com.liferay.portal.kernel.exception.PortalException; 123 124 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure addStructure( 125 long userId, long groupId, long parentStructureId, long classNameId, 126 java.lang.String structureKey, 127 java.util.Map<java.util.Locale, java.lang.String> nameMap, 128 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 129 com.liferay.portlet.dynamicdatamapping.model.DDMForm ddmForm, 130 java.lang.String storageType, int type, 131 com.liferay.portal.service.ServiceContext serviceContext) 132 throws com.liferay.portal.kernel.exception.PortalException; 133 134 /** 135 * Adds a structure referencing its parent structure. 136 * 137 * @param userId the primary key of the structure's creator/owner 138 * @param groupId the primary key of the group 139 * @param parentStructureId the primary key of the parent structure 140 (optionally {@link 141 com.liferay.portlet.dynamicdatamapping.model.DDMStructureConstants#DEFAULT_PARENT_STRUCTURE_ID}) 142 * @param classNameId the primary key of the class name for the 143 structure's related model 144 * @param structureKey the unique string identifying the structure 145 (optionally <code>null</code>) 146 * @param nameMap the structure's locales and localized names 147 * @param descriptionMap the structure's locales and localized 148 descriptions 149 * @param definition the structure's XML schema definition 150 * @param storageType the structure's storage type. It can be "xml" or 151 "expando". For more information, see {@link 152 com.liferay.portlet.dynamicdatamapping.storage.StorageType}. 153 * @param type the structure's type. For more information, see {@link 154 com.liferay.portlet.dynamicdatamapping.model.DDMStructureConstants}. 155 * @param serviceContext the service context to be applied. Can set the 156 UUID, creation date, modification date, guest permissions, 157 and group permissions for the structure. 158 * @return the structure 159 * @throws PortalException if a user with the primary key could not be 160 found, if the XSD was not well-formed, or if a portal 161 exception occurred 162 * @deprecated As of 7.0.0, replaced by {@link #addStructure(long, long, 163 long, long, String, Map, Map, DDMForm, String, int, 164 ServiceContext)} 165 */ 166 @java.lang.Deprecated 167 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure addStructure( 168 long userId, long groupId, long parentStructureId, long classNameId, 169 java.lang.String structureKey, 170 java.util.Map<java.util.Locale, java.lang.String> nameMap, 171 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 172 java.lang.String definition, java.lang.String storageType, int type, 173 com.liferay.portal.service.ServiceContext serviceContext) 174 throws com.liferay.portal.kernel.exception.PortalException; 175 176 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure addStructure( 177 long userId, long groupId, java.lang.String parentStructureKey, 178 long classNameId, java.lang.String structureKey, 179 java.util.Map<java.util.Locale, java.lang.String> nameMap, 180 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 181 com.liferay.portlet.dynamicdatamapping.model.DDMForm ddmForm, 182 java.lang.String storageType, int type, 183 com.liferay.portal.service.ServiceContext serviceContext) 184 throws com.liferay.portal.kernel.exception.PortalException; 185 186 /** 187 * Adds a structure referencing a default parent structure if the parent 188 * structure is not found. 189 * 190 * @param userId the primary key of the structure's creator/owner 191 * @param groupId the primary key of the group 192 * @param parentStructureKey the unique string identifying the parent 193 structure (optionally <code>null</code>) 194 * @param classNameId the primary key of the class name for the 195 structure's related model 196 * @param structureKey the unique string identifying the structure 197 (optionally <code>null</code>) 198 * @param nameMap the structure's locales and localized names 199 * @param descriptionMap the structure's locales and localized 200 descriptions 201 * @param definition the structure's XML schema definition 202 * @param storageType the structure's storage type. It can be "xml" or 203 "expando". For more information, see {@link 204 com.liferay.portlet.dynamicdatamapping.storage.StorageType}. 205 * @param type the structure's type. For more information, see {@link 206 com.liferay.portlet.dynamicdatamapping.model.DDMStructureConstants}. 207 * @param serviceContext the service context to be applied. Can set the 208 UUID, creation date, modification date, guest permissions and 209 group permissions for the structure. 210 * @return the structure 211 * @throws PortalException if a user with the primary key could not be 212 found, if the XSD was not well-formed, or if a portal 213 exception occurred 214 * @deprecated As of 7.0.0, replaced by {@link #addStructure(long, long, 215 String, long, String, Map, Map, DDMForm, String, int, 216 ServiceContext)} 217 */ 218 @java.lang.Deprecated 219 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure addStructure( 220 long userId, long groupId, java.lang.String parentStructureKey, 221 long classNameId, java.lang.String structureKey, 222 java.util.Map<java.util.Locale, java.lang.String> nameMap, 223 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 224 java.lang.String definition, java.lang.String storageType, int type, 225 com.liferay.portal.service.ServiceContext serviceContext) 226 throws com.liferay.portal.kernel.exception.PortalException; 227 228 /** 229 * Adds the resources to the structure. 230 * 231 * @param structure the structure to add resources to 232 * @param addGroupPermissions whether to add group permissions 233 * @param addGuestPermissions whether to add guest permissions 234 * @throws PortalException if a portal exception occurred 235 */ 236 public void addStructureResources( 237 com.liferay.portlet.dynamicdatamapping.model.DDMStructure structure, 238 boolean addGroupPermissions, boolean addGuestPermissions) 239 throws com.liferay.portal.kernel.exception.PortalException; 240 241 /** 242 * Adds the model resources with the permissions to the structure. 243 * 244 * @param structure the structure to add resources to 245 * @param groupPermissions the group permissions to be added 246 * @param guestPermissions the guest permissions to be added 247 * @throws PortalException if a portal exception occurred 248 */ 249 public void addStructureResources( 250 com.liferay.portlet.dynamicdatamapping.model.DDMStructure structure, 251 java.lang.String[] groupPermissions, java.lang.String[] guestPermissions) 252 throws com.liferay.portal.kernel.exception.PortalException; 253 254 public void clearDLFileEntryTypeDDMStructures(long fileEntryTypeId); 255 256 public void clearJournalFolderDDMStructures(long folderId); 257 258 /** 259 * Copies a structure, creating a new structure with all the values 260 * extracted from the original one. The new structure supports a new name 261 * and description. 262 * 263 * @param userId the primary key of the structure's creator/owner 264 * @param structureId the primary key of the structure to be copied 265 * @param nameMap the new structure's locales and localized names 266 * @param descriptionMap the new structure's locales and localized 267 descriptions 268 * @param serviceContext the service context to be applied. Can set the 269 UUID, creation date, modification date, guest permissions, and 270 group permissions for the structure. 271 * @return the new structure 272 * @throws PortalException if a portal exception occurred 273 */ 274 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure copyStructure( 275 long userId, long structureId, 276 java.util.Map<java.util.Locale, java.lang.String> nameMap, 277 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 278 com.liferay.portal.service.ServiceContext serviceContext) 279 throws com.liferay.portal.kernel.exception.PortalException; 280 281 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure copyStructure( 282 long userId, long structureId, 283 com.liferay.portal.service.ServiceContext serviceContext) 284 throws com.liferay.portal.kernel.exception.PortalException; 285 286 /** 287 * Creates a new d d m structure with the primary key. Does not add the d d m structure to the database. 288 * 289 * @param structureId the primary key for the new d d m structure 290 * @return the new d d m structure 291 */ 292 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure createDDMStructure( 293 long structureId); 294 295 /** 296 * Deletes the d d m structure from the database. Also notifies the appropriate model listeners. 297 * 298 * @param ddmStructure the d d m structure 299 * @return the d d m structure that was removed 300 */ 301 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.DELETE) 302 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure deleteDDMStructure( 303 com.liferay.portlet.dynamicdatamapping.model.DDMStructure ddmStructure); 304 305 /** 306 * Deletes the d d m structure with the primary key from the database. Also notifies the appropriate model listeners. 307 * 308 * @param structureId the primary key of the d d m structure 309 * @return the d d m structure that was removed 310 * @throws PortalException if a d d m structure with the primary key could not be found 311 */ 312 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.DELETE) 313 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure deleteDDMStructure( 314 long structureId) 315 throws com.liferay.portal.kernel.exception.PortalException; 316 317 public void deleteDLFileEntryTypeDDMStructure(long fileEntryTypeId, 318 com.liferay.portlet.dynamicdatamapping.model.DDMStructure ddmStructure); 319 320 public void deleteDLFileEntryTypeDDMStructure(long fileEntryTypeId, 321 long structureId); 322 323 public void deleteDLFileEntryTypeDDMStructures(long fileEntryTypeId, 324 java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> DDMStructures); 325 326 public void deleteDLFileEntryTypeDDMStructures(long fileEntryTypeId, 327 long[] structureIds); 328 329 public void deleteJournalFolderDDMStructure(long folderId, 330 com.liferay.portlet.dynamicdatamapping.model.DDMStructure ddmStructure); 331 332 public void deleteJournalFolderDDMStructure(long folderId, long structureId); 333 334 public void deleteJournalFolderDDMStructures(long folderId, 335 java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> DDMStructures); 336 337 public void deleteJournalFolderDDMStructures(long folderId, 338 long[] structureIds); 339 340 /** 341 * @throws PortalException 342 */ 343 @Override 344 public com.liferay.portal.model.PersistedModel deletePersistedModel( 345 com.liferay.portal.model.PersistedModel persistedModel) 346 throws com.liferay.portal.kernel.exception.PortalException; 347 348 /** 349 * Deletes the matching structure and its resources. 350 * 351 * <p> 352 * Before deleting the structure, the system verifies whether the structure 353 * is required by another entity. If it is needed, an exception is thrown. 354 * </p> 355 * 356 * @param groupId the primary key of the group 357 * @param classNameId the primary key of the class name for the structure's 358 related model 359 * @param structureKey the unique string identifying the structure 360 * @throws PortalException if a portal exception occurred 361 */ 362 public void deleteStructure(long groupId, long classNameId, 363 java.lang.String structureKey) 364 throws com.liferay.portal.kernel.exception.PortalException; 365 366 /** 367 * Deletes the structure and its resources. 368 * 369 * <p> 370 * Before deleting the structure, this method verifies whether the structure 371 * is required by another entity. If it is needed, an exception is thrown. 372 * </p> 373 * 374 * @param structure the structure to be deleted 375 * @throws PortalException if a portal exception occurred 376 */ 377 @com.liferay.portal.kernel.systemevent.SystemEvent(type = SystemEventConstants.TYPE_DELETE) 378 public void deleteStructure( 379 com.liferay.portlet.dynamicdatamapping.model.DDMStructure structure) 380 throws com.liferay.portal.kernel.exception.PortalException; 381 382 /** 383 * Deletes the structure and its resources. 384 * 385 * <p> 386 * Before deleting the structure, the system verifies whether the structure 387 * is required by another entity. If it is needed, an exception is thrown. 388 * </p> 389 * 390 * @param structureId the primary key of the structure to be deleted 391 * @throws PortalException if a portal exception occurred 392 */ 393 public void deleteStructure(long structureId) 394 throws com.liferay.portal.kernel.exception.PortalException; 395 396 /** 397 * Deletes all the structures of the group. 398 * 399 * <p> 400 * Before deleting the structures, the system verifies whether each 401 * structure is required by another entity. If any of the structures are 402 * needed, an exception is thrown. 403 * </p> 404 * 405 * @param groupId the primary key of the group 406 * @throws PortalException if a portal exception occurred 407 */ 408 public void deleteStructures(long groupId) 409 throws com.liferay.portal.kernel.exception.PortalException; 410 411 public void deleteStructures(long groupId, long classNameId) 412 throws com.liferay.portal.kernel.exception.PortalException; 413 414 public com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery(); 415 416 /** 417 * Performs a dynamic query on the database and returns the matching rows. 418 * 419 * @param dynamicQuery the dynamic query 420 * @return the matching rows 421 */ 422 public <T> java.util.List<T> dynamicQuery( 423 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery); 424 425 /** 426 * Performs a dynamic query on the database and returns a range of the matching rows. 427 * 428 * <p> 429 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMStructureModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 430 * </p> 431 * 432 * @param dynamicQuery the dynamic query 433 * @param start the lower bound of the range of model instances 434 * @param end the upper bound of the range of model instances (not inclusive) 435 * @return the range of matching rows 436 */ 437 public <T> java.util.List<T> dynamicQuery( 438 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 439 int end); 440 441 /** 442 * Performs a dynamic query on the database and returns an ordered range of the matching rows. 443 * 444 * <p> 445 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMStructureModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 446 * </p> 447 * 448 * @param dynamicQuery the dynamic query 449 * @param start the lower bound of the range of model instances 450 * @param end the upper bound of the range of model instances (not inclusive) 451 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 452 * @return the ordered range of matching rows 453 */ 454 public <T> java.util.List<T> dynamicQuery( 455 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 456 int end, 457 com.liferay.portal.kernel.util.OrderByComparator<T> orderByComparator); 458 459 /** 460 * Returns the number of rows matching the dynamic query. 461 * 462 * @param dynamicQuery the dynamic query 463 * @return the number of rows matching the dynamic query 464 */ 465 public long dynamicQueryCount( 466 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery); 467 468 /** 469 * Returns the number of rows matching the dynamic query. 470 * 471 * @param dynamicQuery the dynamic query 472 * @param projection the projection to apply to the query 473 * @return the number of rows matching the dynamic query 474 */ 475 public long dynamicQueryCount( 476 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, 477 com.liferay.portal.kernel.dao.orm.Projection projection); 478 479 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 480 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure fetchDDMStructure( 481 long structureId); 482 483 /** 484 * Returns the d d m structure matching the UUID and group. 485 * 486 * @param uuid the d d m structure's UUID 487 * @param groupId the primary key of the group 488 * @return the matching d d m structure, or <code>null</code> if a matching d d m structure could not be found 489 */ 490 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 491 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure fetchDDMStructureByUuidAndGroupId( 492 java.lang.String uuid, long groupId); 493 494 /** 495 * Returns the structure matching the class name ID, structure key, and 496 * group. 497 * 498 * @param groupId the primary key of the group 499 * @param classNameId the primary key of the class name for the structure's 500 related model 501 * @param structureKey the unique string identifying the structure 502 * @return the matching structure, or <code>null</code> if a matching 503 structure could not be found 504 */ 505 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 506 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure fetchStructure( 507 long groupId, long classNameId, java.lang.String structureKey); 508 509 /** 510 * Returns the structure matching the class name ID, structure key, and 511 * group, optionally searching ancestor sites (that have sharing enabled) 512 * and global scoped sites. 513 * 514 * <p> 515 * This method first searches in the group. If the structure is still not 516 * found and <code>includeAncestorStructures</code> is set to 517 * <code>true</code>, this method searches the group's ancestor sites (that 518 * have sharing enabled) and lastly searches global scoped sites. 519 * </p> 520 * 521 * @param groupId the primary key of the group 522 * @param classNameId the primary key of the class name for the structure's 523 related model 524 * @param structureKey the unique string identifying the structure 525 * @param includeAncestorStructures whether to include ancestor sites (that 526 have sharing enabled) and include global scoped sites in the 527 search 528 * @return the matching structure, or <code>null</code> if a matching 529 structure could not be found 530 * @throws PortalException if a portal exception occurred 531 */ 532 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 533 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure fetchStructure( 534 long groupId, long classNameId, java.lang.String structureKey, 535 boolean includeAncestorStructures) 536 throws com.liferay.portal.kernel.exception.PortalException; 537 538 /** 539 * Returns the structure with the ID. 540 * 541 * @param structureId the primary key of the structure 542 * @return the structure with the structure ID, or <code>null</code> if a 543 matching structure could not be found 544 */ 545 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 546 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure fetchStructure( 547 long structureId); 548 549 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 550 public com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery getActionableDynamicQuery(); 551 552 /** 553 * Returns the Spring bean ID for this bean. 554 * 555 * @return the Spring bean ID for this bean 556 */ 557 public java.lang.String getBeanIdentifier(); 558 559 /** 560 * @deprecated As of 6.2.0, replaced by {@link #getClassStructures(long, 561 long)} 562 */ 563 @java.lang.Deprecated 564 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 565 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getClassStructures( 566 long classNameId); 567 568 /** 569 * @deprecated As of 6.2.0, replaced by {@link #getClassStructures(long, 570 long, OrderByComparator)} 571 */ 572 @java.lang.Deprecated 573 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 574 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getClassStructures( 575 long classNameId, 576 com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> orderByComparator); 577 578 /** 579 * @deprecated As of 6.2.0, replaced by {@link #getClassStructures(long, 580 long, int, int)} 581 */ 582 @java.lang.Deprecated 583 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 584 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getClassStructures( 585 long classNameId, int start, int end); 586 587 /** 588 * Returns all the structures matching the class name ID. 589 * 590 * @param companyId the primary key of the structure's company 591 * @param classNameId the primary key of the class name for the structure's 592 related model 593 * @return the structures matching the class name ID 594 */ 595 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 596 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getClassStructures( 597 long companyId, long classNameId); 598 599 /** 600 * Returns all the structures matching the class name ID ordered by the 601 * comparator. 602 * 603 * @param companyId the primary key of the structure's company 604 * @param classNameId the primary key of the class name for the structure's 605 related model 606 * @param orderByComparator the comparator to order the structures 607 (optionally <code>null</code>) 608 * @return the matching structures ordered by the comparator 609 */ 610 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 611 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getClassStructures( 612 long companyId, long classNameId, 613 com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> orderByComparator); 614 615 /** 616 * Returns a range of all the structures matching the class name ID. 617 * 618 * <p> 619 * Useful when paginating results. Returns a maximum of <code>end - 620 * start</code> instances. <code>start</code> and <code>end</code> are not 621 * primary keys, they are indexes in the result set. Thus, <code>0</code> 622 * refers to the first result in the set. Setting both <code>start</code> 623 * and <code>end</code> to {@link 624 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full 625 * result set. 626 * </p> 627 * 628 * @param companyId the primary key of the structure's company 629 * @param classNameId the primary key of the class name for the structure's 630 related model 631 * @param start the lower bound of the range of structures to return 632 * @param end the upper bound of the range of structures to return (not 633 inclusive) 634 * @return the range of matching structures 635 */ 636 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 637 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getClassStructures( 638 long companyId, long classNameId, int start, int end); 639 640 /** 641 * Returns the d d m structure with the primary key. 642 * 643 * @param structureId the primary key of the d d m structure 644 * @return the d d m structure 645 * @throws PortalException if a d d m structure with the primary key could not be found 646 */ 647 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 648 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure getDDMStructure( 649 long structureId) 650 throws com.liferay.portal.kernel.exception.PortalException; 651 652 /** 653 * Returns the d d m structure matching the UUID and group. 654 * 655 * @param uuid the d d m structure's UUID 656 * @param groupId the primary key of the group 657 * @return the matching d d m structure 658 * @throws PortalException if a matching d d m structure could not be found 659 */ 660 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 661 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure getDDMStructureByUuidAndGroupId( 662 java.lang.String uuid, long groupId) 663 throws com.liferay.portal.kernel.exception.PortalException; 664 665 /** 666 * Returns a range of all the d d m structures. 667 * 668 * <p> 669 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.dynamicdatamapping.model.impl.DDMStructureModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 670 * </p> 671 * 672 * @param start the lower bound of the range of d d m structures 673 * @param end the upper bound of the range of d d m structures (not inclusive) 674 * @return the range of d d m structures 675 */ 676 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 677 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getDDMStructures( 678 int start, int end); 679 680 /** 681 * Returns all the d d m structures matching the UUID and company. 682 * 683 * @param uuid the UUID of the d d m structures 684 * @param companyId the primary key of the company 685 * @return the matching d d m structures, or an empty list if no matches were found 686 */ 687 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 688 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getDDMStructuresByUuidAndCompanyId( 689 java.lang.String uuid, long companyId); 690 691 /** 692 * Returns a range of d d m structures matching the UUID and company. 693 * 694 * @param uuid the UUID of the d d m structures 695 * @param companyId the primary key of the company 696 * @param start the lower bound of the range of d d m structures 697 * @param end the upper bound of the range of d d m structures (not inclusive) 698 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 699 * @return the range of matching d d m structures, or an empty list if no matches were found 700 */ 701 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 702 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getDDMStructuresByUuidAndCompanyId( 703 java.lang.String uuid, long companyId, int start, int end, 704 com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> orderByComparator); 705 706 /** 707 * Returns the number of d d m structures. 708 * 709 * @return the number of d d m structures 710 */ 711 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 712 public int getDDMStructuresCount(); 713 714 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 715 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getDLFileEntryTypeDDMStructures( 716 long fileEntryTypeId); 717 718 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 719 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getDLFileEntryTypeDDMStructures( 720 long fileEntryTypeId, int start, int end); 721 722 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 723 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getDLFileEntryTypeDDMStructures( 724 long fileEntryTypeId, int start, int end, 725 com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> orderByComparator); 726 727 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 728 public int getDLFileEntryTypeDDMStructuresCount(long fileEntryTypeId); 729 730 /** 731 * Returns the fileEntryTypeIds of the document library file entry types associated with the d d m structure. 732 * 733 * @param structureId the structureId of the d d m structure 734 * @return long[] the fileEntryTypeIds of document library file entry types associated with the d d m structure 735 */ 736 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 737 public long[] getDLFileEntryTypePrimaryKeys(long structureId); 738 739 /** 740 * Returns all the structures for the document library file entry type. 741 * 742 * @param dlFileEntryTypeId the primary key of the document library file 743 entry type 744 * @return the structures for the document library file entry type 745 */ 746 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 747 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getDLFileEntryTypeStructures( 748 long dlFileEntryTypeId); 749 750 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 751 public com.liferay.portal.kernel.dao.orm.ExportActionableDynamicQuery getExportActionableDynamicQuery( 752 com.liferay.portal.kernel.lar.PortletDataContext portletDataContext); 753 754 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 755 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getJournalFolderDDMStructures( 756 long folderId); 757 758 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 759 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getJournalFolderDDMStructures( 760 long folderId, int start, int end); 761 762 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 763 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getJournalFolderDDMStructures( 764 long folderId, int start, int end, 765 com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> orderByComparator); 766 767 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 768 public int getJournalFolderDDMStructuresCount(long folderId); 769 770 /** 771 * Returns the folderIds of the journal folders associated with the d d m structure. 772 * 773 * @param structureId the structureId of the d d m structure 774 * @return long[] the folderIds of journal folders associated with the d d m structure 775 */ 776 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 777 public long[] getJournalFolderPrimaryKeys(long structureId); 778 779 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 780 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getJournalFolderStructures( 781 long[] groupIds, long journalFolderId, int restrictionType) 782 throws com.liferay.portal.kernel.exception.PortalException; 783 784 @Override 785 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 786 public com.liferay.portal.model.PersistedModel getPersistedModel( 787 java.io.Serializable primaryKeyObj) 788 throws com.liferay.portal.kernel.exception.PortalException; 789 790 /** 791 * Returns the structure matching the class name ID, structure key, and 792 * group. 793 * 794 * @param groupId the primary key of the structure's group 795 * @param classNameId the primary key of the class name for the structure's 796 related model 797 * @param structureKey the unique string identifying the structure 798 * @return the matching structure 799 * @throws PortalException if a matching structure could not be found 800 */ 801 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 802 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure getStructure( 803 long groupId, long classNameId, java.lang.String structureKey) 804 throws com.liferay.portal.kernel.exception.PortalException; 805 806 /** 807 * Returns the structure matching the class name ID, structure key, and 808 * group, optionally searching ancestor sites (that have sharing enabled) 809 * and global scoped sites. 810 * 811 * <p> 812 * This method first searches in the group. If the structure is still not 813 * found and <code>includeAncestorStructures</code> is set to 814 * <code>true</code>, this method searches the group's ancestor sites (that 815 * have sharing enabled) and lastly searches global scoped sites. 816 * </p> 817 * 818 * @param groupId the primary key of the structure's group 819 * @param classNameId the primary key of the class name for the structure's 820 related model 821 * @param structureKey the unique string identifying the structure 822 * @param includeAncestorStructures whether to include ancestor sites (that 823 have sharing enabled) and include global scoped sites in the 824 search in the search 825 * @return the matching structure 826 * @throws PortalException if a matching structure could not be found 827 */ 828 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 829 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure getStructure( 830 long groupId, long classNameId, java.lang.String structureKey, 831 boolean includeAncestorStructures) 832 throws com.liferay.portal.kernel.exception.PortalException; 833 834 /** 835 * Returns all the structures matching the group, name, and description. 836 * 837 * @param groupId the primary key of the structure's group 838 * @param name the structure's name 839 * @param description the structure's description 840 * @return the matching structures 841 */ 842 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 843 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructure( 844 long groupId, java.lang.String name, java.lang.String description); 845 846 /** 847 * Returns the structure with the ID. 848 * 849 * @param structureId the primary key of the structure 850 * @return the structure with the ID 851 * @throws PortalException if a structure with the ID could not be found 852 */ 853 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 854 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure getStructure( 855 long structureId) 856 throws com.liferay.portal.kernel.exception.PortalException; 857 858 /** 859 * @deprecated As of 6.2.0, replaced by {@link #getStructures} 860 */ 861 @java.lang.Deprecated 862 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 863 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructureEntries(); 864 865 /** 866 * @deprecated As of 6.2.0, replaced by {@link #getStructures(long)} 867 */ 868 @java.lang.Deprecated 869 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 870 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructureEntries( 871 long groupId); 872 873 /** 874 * @deprecated As of 6.2.0, replaced by {@link #getStructures(long, int, 875 int)} 876 */ 877 @java.lang.Deprecated 878 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 879 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructureEntries( 880 long groupId, int start, int end); 881 882 /** 883 * Returns all the structures present in the system. 884 * 885 * @return the structures present in the system 886 */ 887 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 888 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructures(); 889 890 /** 891 * Returns all the structures present in the group. 892 * 893 * @param groupId the primary key of the group 894 * @return the structures present in the group 895 */ 896 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 897 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructures( 898 long groupId); 899 900 /** 901 * Returns all the structures matching class name ID and group. 902 * 903 * @param groupId the primary key of the group 904 * @param classNameId the primary key of the class name for the structure's 905 related model 906 * @return the matching structures 907 */ 908 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 909 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructures( 910 long groupId, long classNameId); 911 912 /** 913 * Returns a range of all the structures that match the class name ID and 914 * group. 915 * 916 * <p> 917 * Useful when paginating results. Returns a maximum of <code>end - 918 * start</code> instances. <code>start</code> and <code>end</code> are not 919 * primary keys, they are indexes in the result set. Thus, <code>0</code> 920 * refers to the first result in the set. Setting both <code>start</code> 921 * and <code>end</code> to {@link 922 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full 923 * result set. 924 * </p> 925 * 926 * @param groupId the primary key of the group 927 * @param classNameId the primary key of the class name for the structure's 928 related model 929 * @param start the lower bound of the range of structures to return 930 * @param end the upper bound of the range of structures to return (not 931 inclusive) 932 * @return the range of matching structures 933 */ 934 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 935 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructures( 936 long groupId, long classNameId, int start, int end); 937 938 /** 939 * Returns an ordered range of all the structures matching the class name ID 940 * and group. 941 * 942 * <p> 943 * Useful when paginating results. Returns a maximum of <code>end - 944 * start</code> instances. <code>start</code> and <code>end</code> are not 945 * primary keys, they are indexes in the result set. Thus, <code>0</code> 946 * refers to the first result in the set. Setting both <code>start</code> 947 * and <code>end</code> to {@link 948 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full 949 * result set. 950 * </p> 951 * 952 * @param groupId the primary key of the group 953 * @param classNameId the primary key of the class name for the structure's 954 related model 955 * @param start the lower bound of the range of structures to return 956 * @param end the upper bound of the range of structures to return (not 957 inclusive) 958 * @param orderByComparator the comparator to order the structures 959 (optionally <code>null</code>) 960 * @return the range of matching structures ordered by the comparator 961 */ 962 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 963 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructures( 964 long groupId, long classNameId, int start, int end, 965 com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> orderByComparator); 966 967 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 968 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructures( 969 long groupId, java.lang.String name, java.lang.String description); 970 971 /** 972 * Returns a range of all the structures belonging to the group. 973 * 974 * <p> 975 * Useful when paginating results. Returns a maximum of <code>end - 976 * start</code> instances. <code>start</code> and <code>end</code> are not 977 * primary keys, they are indexes in the result set. Thus, <code>0</code> 978 * refers to the first result in the set. Setting both <code>start</code> 979 * and <code>end</code> to {@link 980 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full 981 * result set. 982 * </p> 983 * 984 * @param groupId the primary key of the group 985 * @param start the lower bound of the range of structures to return 986 * @param end the upper bound of the range of structures to return (not 987 inclusive) 988 * @return the range of matching structures 989 */ 990 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 991 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructures( 992 long groupId, int start, int end); 993 994 /** 995 * Returns all the structures belonging to the groups. 996 * 997 * @param groupIds the primary keys of the groups 998 * @return the structures belonging to the groups 999 */ 1000 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1001 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructures( 1002 long[] groupIds); 1003 1004 /** 1005 * Returns all the structures matching the class name ID and belonging to 1006 * the groups. 1007 * 1008 * @param groupIds the primary keys of the groups 1009 * @param classNameId the primary key of the class name for the structure's 1010 related model 1011 * @return the matching structures 1012 */ 1013 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1014 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructures( 1015 long[] groupIds, long classNameId); 1016 1017 /** 1018 * Returns a range of all the structures matching the class name ID and 1019 * belonging to the groups. 1020 * 1021 * <p> 1022 * Useful when paginating results. Returns a maximum of <code>end - 1023 * start</code> instances. <code>start</code> and <code>end</code> are not 1024 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1025 * refers to the first result in the set. Setting both <code>start</code> 1026 * and <code>end</code> to {@link 1027 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full 1028 * result set. 1029 * </p> 1030 * 1031 * @param groupIds the primary keys of the groups 1032 * @param classNameId the primary key of the class name for the structure's 1033 related model 1034 * @param start the lower bound of the range of structures to return 1035 * @param end the upper bound of the range of structures to return (not 1036 inclusive) 1037 * @return the range of matching structures 1038 */ 1039 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1040 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> getStructures( 1041 long[] groupIds, long classNameId, int start, int end); 1042 1043 /** 1044 * Returns the number of structures belonging to the group. 1045 * 1046 * @param groupId the primary key of the group 1047 * @return the number of structures belonging to the group 1048 */ 1049 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1050 public int getStructuresCount(long groupId); 1051 1052 /** 1053 * Returns the number of structures matching the class name ID and group. 1054 * 1055 * @param groupId the primary key of the group 1056 * @param classNameId the primary key of the class name for the structure's 1057 related model 1058 * @return the number of matching structures 1059 */ 1060 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1061 public int getStructuresCount(long groupId, long classNameId); 1062 1063 /** 1064 * Returns the number of structures matching the class name ID and belonging 1065 * to the groups. 1066 * 1067 * @param groupIds the primary keys of the groups 1068 * @param classNameId the primary key of the class name for the structure's 1069 related model 1070 * @return the number of matching structures 1071 */ 1072 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1073 public int getStructuresCount(long[] groupIds, long classNameId); 1074 1075 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1076 public boolean hasDLFileEntryTypeDDMStructure(long fileEntryTypeId, 1077 long structureId); 1078 1079 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1080 public boolean hasDLFileEntryTypeDDMStructures(long fileEntryTypeId); 1081 1082 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1083 public boolean hasJournalFolderDDMStructure(long folderId, long structureId); 1084 1085 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1086 public boolean hasJournalFolderDDMStructures(long folderId); 1087 1088 /** 1089 * Returns an ordered range of all the structures matching the groups and 1090 * class name IDs, and matching the keywords in the structure names and 1091 * descriptions. 1092 * 1093 * <p> 1094 * Useful when paginating results. Returns a maximum of <code>end - 1095 * start</code> instances. <code>start</code> and <code>end</code> are not 1096 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1097 * refers to the first result in the set. Setting both <code>start</code> 1098 * and <code>end</code> to {@link 1099 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full 1100 * result set. 1101 * </p> 1102 * 1103 * @param companyId the primary key of the structure's company 1104 * @param groupIds the primary keys of the groups 1105 * @param classNameIds the primary keys of the class names of the models 1106 the structures are related to 1107 * @param keywords the keywords (space separated), which may occur in the 1108 structure's name or description (optionally <code>null</code>) 1109 * @param start the lower bound of the range of structures to return 1110 * @param end the upper bound of the range of structures to return (not 1111 inclusive) 1112 * @param orderByComparator the comparator to order the structures 1113 (optionally <code>null</code>) 1114 * @return the range of matching structures ordered by the comparator 1115 */ 1116 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1117 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> search( 1118 long companyId, long[] groupIds, long[] classNameIds, 1119 java.lang.String keywords, int start, int end, 1120 com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> orderByComparator); 1121 1122 /** 1123 * Returns an ordered range of all the structures matching the groups, class 1124 * name IDs, name keyword, description keyword, storage type, and type. 1125 * 1126 * <p> 1127 * Useful when paginating results. Returns a maximum of <code>end - 1128 * start</code> instances. <code>start</code> and <code>end</code> are not 1129 * primary keys, they are indexes in the result set. Thus, <code>0</code> 1130 * refers to the first result in the set. Setting both <code>start</code> 1131 * and <code>end</code> to {@link 1132 * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full 1133 * result set. 1134 * </p> 1135 * 1136 * @param companyId the primary key of the structure's company 1137 * @param groupIds the primary keys of the groups 1138 * @param classNameIds the primary keys of the class names of the models 1139 the structures are related to 1140 * @param name the name keywords 1141 * @param description the description keywords 1142 * @param storageType the structure's storage type. It can be "xml" or 1143 "expando". For more information, see {@link 1144 com.liferay.portlet.dynamicdatamapping.storage.StorageType}. 1145 * @param type the structure's type. For more information, see {@link 1146 com.liferay.portlet.dynamicdatamapping.model.DDMStructureConstants}. 1147 * @param andOperator whether every field must match its keywords, or just 1148 one field 1149 * @param start the lower bound of the range of structures to return 1150 * @param end the upper bound of the range of structures to return (not 1151 inclusive) 1152 * @param orderByComparator the comparator to order the structures 1153 (optionally <code>null</code>) 1154 * @return the range of matching structures ordered by the comparator 1155 */ 1156 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1157 public java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> search( 1158 long companyId, long[] groupIds, long[] classNameIds, 1159 java.lang.String name, java.lang.String description, 1160 java.lang.String storageType, int type, boolean andOperator, int start, 1161 int end, 1162 com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.dynamicdatamapping.model.DDMStructure> orderByComparator); 1163 1164 /** 1165 * Returns the number of structures matching the groups and class name IDs, 1166 * and matching the keywords in the structure names and descriptions. 1167 * 1168 * @param companyId the primary key of the structure's company 1169 * @param groupIds the primary keys of the groups 1170 * @param classNameIds the primary keys of the class names of the models 1171 the structures are related to 1172 * @param keywords the keywords (space separated), which may occur in the 1173 structure's name or description (optionally <code>null</code>) 1174 * @return the number of matching structures 1175 */ 1176 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1177 public int searchCount(long companyId, long[] groupIds, 1178 long[] classNameIds, java.lang.String keywords); 1179 1180 /** 1181 * Returns the number of structures matching the groups, class name IDs, 1182 * name keyword, description keyword, storage type, and type 1183 * 1184 * @param companyId the primary key of the structure's company 1185 * @param groupIds the primary keys of the groups 1186 * @param classNameIds the primary keys of the class names of the models 1187 the structure's are related to 1188 * @param name the name keywords 1189 * @param description the description keywords 1190 * @param storageType the structure's storage type. It can be "xml" or 1191 "expando". For more information, see {@link 1192 com.liferay.portlet.dynamicdatamapping.storage.StorageType}. 1193 * @param type the structure's type. For more information, see {@link 1194 com.liferay.portlet.dynamicdatamapping.model.DDMStructureConstants}. 1195 * @param andOperator whether every field must match its keywords, or just 1196 one field 1197 * @return the number of matching structures 1198 */ 1199 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true) 1200 public int searchCount(long companyId, long[] groupIds, 1201 long[] classNameIds, java.lang.String name, 1202 java.lang.String description, java.lang.String storageType, int type, 1203 boolean andOperator); 1204 1205 /** 1206 * Sets the Spring bean ID for this bean. 1207 * 1208 * @param beanIdentifier the Spring bean ID for this bean 1209 */ 1210 public void setBeanIdentifier(java.lang.String beanIdentifier); 1211 1212 public void setDLFileEntryTypeDDMStructures(long fileEntryTypeId, 1213 long[] structureIds); 1214 1215 public void setJournalFolderDDMStructures(long folderId, long[] structureIds); 1216 1217 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure updateDDMForm( 1218 long structureId, 1219 com.liferay.portlet.dynamicdatamapping.model.DDMForm ddmForm, 1220 com.liferay.portal.service.ServiceContext serviceContext) 1221 throws com.liferay.portal.kernel.exception.PortalException; 1222 1223 /** 1224 * Updates the d d m structure in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners. 1225 * 1226 * @param ddmStructure the d d m structure 1227 * @return the d d m structure that was updated 1228 */ 1229 @com.liferay.portal.kernel.search.Indexable(type = IndexableType.REINDEX) 1230 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure updateDDMStructure( 1231 com.liferay.portlet.dynamicdatamapping.model.DDMStructure ddmStructure); 1232 1233 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure updateStructure( 1234 long groupId, long parentStructureId, long classNameId, 1235 java.lang.String structureKey, 1236 java.util.Map<java.util.Locale, java.lang.String> nameMap, 1237 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 1238 com.liferay.portlet.dynamicdatamapping.model.DDMForm ddmForm, 1239 com.liferay.portal.service.ServiceContext serviceContext) 1240 throws com.liferay.portal.kernel.exception.PortalException; 1241 1242 /** 1243 * Updates the structure matching the class name ID, structure key, and 1244 * group, replacing its old parent structure, name map, description map, and 1245 * XSD with new ones. 1246 * 1247 * @param groupId the primary key of the group 1248 * @param parentStructureId the primary key of the new parent structure 1249 * @param classNameId the primary key of the class name for the 1250 structure's related model 1251 * @param structureKey the unique string identifying the structure 1252 * @param nameMap the structure's new locales and localized names 1253 * @param descriptionMap the structure's new locales and localized 1254 description 1255 * @param definition the structure's new XML schema definition 1256 * @param serviceContext the service context to be applied. Can set the 1257 structure's modification date. 1258 * @return the updated structure 1259 * @throws PortalException if a matching structure could not be found, 1260 if the XSD was not well-formed, or if a portal exception 1261 occurred 1262 * @deprecated As of 7.0.0, replaced by {@link #updateStructure(long, long, 1263 long, String, Map, Map, DDMForm, ServiceContext)} 1264 */ 1265 @java.lang.Deprecated 1266 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure updateStructure( 1267 long groupId, long parentStructureId, long classNameId, 1268 java.lang.String structureKey, 1269 java.util.Map<java.util.Locale, java.lang.String> nameMap, 1270 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 1271 java.lang.String definition, 1272 com.liferay.portal.service.ServiceContext serviceContext) 1273 throws com.liferay.portal.kernel.exception.PortalException; 1274 1275 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure updateStructure( 1276 long structureId, long parentStructureId, 1277 java.util.Map<java.util.Locale, java.lang.String> nameMap, 1278 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 1279 com.liferay.portlet.dynamicdatamapping.model.DDMForm ddmForm, 1280 com.liferay.portal.service.ServiceContext serviceContext) 1281 throws com.liferay.portal.kernel.exception.PortalException; 1282 1283 /** 1284 * Updates the structure matching the structure ID, replacing its old parent 1285 * structure, name map, description map, and XSD with new ones. 1286 * 1287 * @param structureId the primary key of the structure 1288 * @param parentStructureId the primary key of the new parent structure 1289 * @param nameMap the structure's new locales and localized names 1290 * @param descriptionMap the structure's new locales and localized 1291 descriptions 1292 * @param definition the structure's new XML schema definition 1293 * @param serviceContext the service context to be applied. Can set the 1294 structure's modification date. 1295 * @return the updated structure 1296 * @throws PortalException if a matching structure could not be found, 1297 if the XSD was not well-formed, or if a portal exception 1298 occurred 1299 * @deprecated As of 7.0.0, replaced by {@link #updateStructure(long, long, 1300 Map, Map, DDMForm, ServiceContext)} 1301 */ 1302 @java.lang.Deprecated 1303 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure updateStructure( 1304 long structureId, long parentStructureId, 1305 java.util.Map<java.util.Locale, java.lang.String> nameMap, 1306 java.util.Map<java.util.Locale, java.lang.String> descriptionMap, 1307 java.lang.String definition, 1308 com.liferay.portal.service.ServiceContext serviceContext) 1309 throws com.liferay.portal.kernel.exception.PortalException; 1310 1311 /** 1312 * Updates the structure matching the structure ID, replacing its XSD with a 1313 * new one. 1314 * 1315 * @param structureId the primary key of the structure 1316 * @param definition the structure's new XML schema definition 1317 * @param serviceContext the service context to be applied. Can set the 1318 structure's modification date. 1319 * @return the updated structure 1320 * @throws PortalException if a matching structure could not be found, 1321 if the XSD was not well-formed, or if a portal exception 1322 occurred 1323 * @deprecated As of 7.0.0, replaced by {@link #updateDDMForm(long, String, 1324 ServiceContext)} 1325 */ 1326 @java.lang.Deprecated 1327 public com.liferay.portlet.dynamicdatamapping.model.DDMStructure updateXSD( 1328 long structureId, java.lang.String definition, 1329 com.liferay.portal.service.ServiceContext serviceContext) 1330 throws com.liferay.portal.kernel.exception.PortalException; 1331 }