Class ImageLocalServiceWrapper
- All Implemented Interfaces:
BaseLocalService
,CTService<Image>
,ImageLocalService
,PersistedModelLocalService
,ServiceWrapper<ImageLocalService>
ImageLocalService
.- Author:
- Brian Wing Shun Chan
- See Also:
- {$generated.description}
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionAdds the image to the database.createImage
(long imageId) Creates a new image with the primary key.createPersistedModel
(Serializable primaryKeyObj) deleteImage
(long imageId) Deletes the image with the primary key from the database.deleteImage
(Image image) Deletes the image from the database.deletePersistedModel
(PersistedModel persistedModel) <T> T
dslQuery
(com.liferay.petra.sql.dsl.query.DSLQuery dslQuery) int
dslQueryCount
(com.liferay.petra.sql.dsl.query.DSLQuery dslQuery) <T> List<T>
dynamicQuery
(DynamicQuery dynamicQuery) Performs a dynamic query on the database and returns the matching rows.<T> List<T>
dynamicQuery
(DynamicQuery dynamicQuery, int start, int end) Performs a dynamic query on the database and returns a range of the matching rows.<T> List<T>
dynamicQuery
(DynamicQuery dynamicQuery, int start, int end, OrderByComparator<T> orderByComparator) Performs a dynamic query on the database and returns an ordered range of the matching rows.long
dynamicQueryCount
(DynamicQuery dynamicQuery) Returns the number of rows matching the dynamic query.long
dynamicQueryCount
(DynamicQuery dynamicQuery, Projection projection) Returns the number of rows matching the dynamic query.fetchImage
(long imageId) getCompanyLogo
(long imageId) getImage
(long imageId) Returns the image with the primary key.getImageInputStream
(long companyId, long imageId, String type) getImageOrDefault
(long imageId) getImages
(int start, int end) Returns a range of all the images.getImagesBySize
(int size) int
Returns the number of images.Returns the OSGi service identifier.getPersistedModel
(Serializable primaryKeyObj) moveImage
(long imageId, byte[] bytes) void
setWrappedService
(ImageLocalService imageLocalService) updateImage
(long imageId, byte[] bytes) Deprecated.updateImage
(long imageId, byte[] bytes, String type, int height, int width, int size) Deprecated.As of Cavanaugh (7.4.x), replaced byupdateImage(long, long, byte[], String, int, int, int)
updateImage
(long companyId, long imageId, byte[] bytes) updateImage
(long companyId, long imageId, byte[] bytes, String type, int height, int width, int size) updateImage
(long companyId, long imageId, File file) updateImage
(long companyId, long imageId, InputStream inputStream) updateImage
(long companyId, long imageId, InputStream inputStream, boolean cleanUpStream) updateImage
(long imageId, File file) Deprecated.As of Cavanaugh (7.4.x), replaced byupdateImage(long, long, File)
updateImage
(long imageId, InputStream inputStream) Deprecated.As of Cavanaugh (7.4.x), replaced byupdateImage(long, long, InputStream)
updateImage
(long imageId, InputStream inputStream, boolean cleanUpStream) Deprecated.As of Cavanaugh (7.4.x), replaced byupdateImage(long, long, InputStream, boolean)
updateImage
(Image image) Updates the image in the database or adds it if it does not yet exist.<R,
E extends Throwable>
RupdateWithUnsafeFunction
(com.liferay.petra.function.UnsafeFunction<CTPersistence<Image>, R, E> updateUnsafeFunction) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.liferay.portal.kernel.service.PersistedModelLocalService
fetchPersistedModel
-
Constructor Details
-
ImageLocalServiceWrapper
public ImageLocalServiceWrapper() -
ImageLocalServiceWrapper
-
-
Method Details
-
addImage
Adds the image to the database. Also notifies the appropriate model listeners.Important: Inspect ImageLocalServiceImpl for overloaded versions of the method. If provided, use these entry points to the API, as the implementation logic may require the additional parameters defined there.
- Specified by:
addImage
in interfaceImageLocalService
- Parameters:
image
- the image- Returns:
- the image that was added
-
createImage
Creates a new image with the primary key. Does not add the image to the database.- Specified by:
createImage
in interfaceImageLocalService
- Parameters:
imageId
- the primary key for the new image- Returns:
- the new image
-
createPersistedModel
- Specified by:
createPersistedModel
in interfaceImageLocalService
- Specified by:
createPersistedModel
in interfacePersistedModelLocalService
- Throws:
PortalException
PortalException
-
deleteImage
Deletes the image from the database. Also notifies the appropriate model listeners.Important: Inspect ImageLocalServiceImpl for overloaded versions of the method. If provided, use these entry points to the API, as the implementation logic may require the additional parameters defined there.
- Specified by:
deleteImage
in interfaceImageLocalService
- Parameters:
image
- the image- Returns:
- the image that was removed
-
deleteImage
Deletes the image with the primary key from the database. Also notifies the appropriate model listeners.Important: Inspect ImageLocalServiceImpl for overloaded versions of the method. If provided, use these entry points to the API, as the implementation logic may require the additional parameters defined there.
- Specified by:
deleteImage
in interfaceImageLocalService
- Parameters:
imageId
- the primary key of the image- Returns:
- the image that was removed
- Throws:
PortalException
- if a image with the primary key could not be foundPortalException
-
deletePersistedModel
- Specified by:
deletePersistedModel
in interfaceImageLocalService
- Specified by:
deletePersistedModel
in interfacePersistedModelLocalService
- Throws:
PortalException
PortalException
-
dslQuery
public <T> T dslQuery(com.liferay.petra.sql.dsl.query.DSLQuery dslQuery) - Specified by:
dslQuery
in interfaceImageLocalService
- Specified by:
dslQuery
in interfacePersistedModelLocalService
-
dslQueryCount
public int dslQueryCount(com.liferay.petra.sql.dsl.query.DSLQuery dslQuery) - Specified by:
dslQueryCount
in interfaceImageLocalService
- Specified by:
dslQueryCount
in interfacePersistedModelLocalService
-
dynamicQuery
- Specified by:
dynamicQuery
in interfaceImageLocalService
-
dynamicQuery
Performs a dynamic query on the database and returns the matching rows.- Specified by:
dynamicQuery
in interfaceImageLocalService
- Parameters:
dynamicQuery
- the dynamic query- Returns:
- the matching rows
-
dynamicQuery
Performs a dynamic query on the database and returns a range of the matching rows.Useful when paginating results. Returns a maximum of
end - start
instances.start
andend
are not primary keys, they are indexes in the result set. Thus,0
refers to the first result in the set. Setting bothstart
andend
tocom.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS
will return the full result set. IforderByComparator
is specified, then the query will include the given ORDER BY logic. IforderByComparator
is absent, then the query will include the default ORDER BY logic fromcom.liferay.portal.model.impl.ImageModelImpl
.- Specified by:
dynamicQuery
in interfaceImageLocalService
- Parameters:
dynamicQuery
- the dynamic querystart
- the lower bound of the range of model instancesend
- the upper bound of the range of model instances (not inclusive)- Returns:
- the range of matching rows
-
dynamicQuery
public <T> List<T> dynamicQuery(DynamicQuery dynamicQuery, int start, int end, OrderByComparator<T> orderByComparator) Performs a dynamic query on the database and returns an ordered range of the matching rows.Useful when paginating results. Returns a maximum of
end - start
instances.start
andend
are not primary keys, they are indexes in the result set. Thus,0
refers to the first result in the set. Setting bothstart
andend
tocom.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS
will return the full result set. IforderByComparator
is specified, then the query will include the given ORDER BY logic. IforderByComparator
is absent, then the query will include the default ORDER BY logic fromcom.liferay.portal.model.impl.ImageModelImpl
.- Specified by:
dynamicQuery
in interfaceImageLocalService
- Parameters:
dynamicQuery
- the dynamic querystart
- the lower bound of the range of model instancesend
- the upper bound of the range of model instances (not inclusive)orderByComparator
- the comparator to order the results by (optionallynull
)- Returns:
- the ordered range of matching rows
-
dynamicQueryCount
Returns the number of rows matching the dynamic query.- Specified by:
dynamicQueryCount
in interfaceImageLocalService
- Parameters:
dynamicQuery
- the dynamic query- Returns:
- the number of rows matching the dynamic query
-
dynamicQueryCount
Returns the number of rows matching the dynamic query.- Specified by:
dynamicQueryCount
in interfaceImageLocalService
- Parameters:
dynamicQuery
- the dynamic queryprojection
- the projection to apply to the query- Returns:
- the number of rows matching the dynamic query
-
fetchImage
- Specified by:
fetchImage
in interfaceImageLocalService
-
getActionableDynamicQuery
- Specified by:
getActionableDynamicQuery
in interfaceImageLocalService
-
getCompanyLogo
- Specified by:
getCompanyLogo
in interfaceImageLocalService
-
getImage
Returns the image with the primary key.- Specified by:
getImage
in interfaceImageLocalService
- Parameters:
imageId
- the primary key of the image- Returns:
- the image
- Throws:
PortalException
- if a image with the primary key could not be foundPortalException
-
getImageInputStream
public InputStream getImageInputStream(long companyId, long imageId, String type) throws PortalException - Specified by:
getImageInputStream
in interfaceImageLocalService
- Throws:
PortalException
-
getImageOrDefault
- Specified by:
getImageOrDefault
in interfaceImageLocalService
-
getImages
- Specified by:
getImages
in interfaceImageLocalService
-
getImages
Returns a range of all the images.Useful when paginating results. Returns a maximum of
end - start
instances.start
andend
are not primary keys, they are indexes in the result set. Thus,0
refers to the first result in the set. Setting bothstart
andend
tocom.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS
will return the full result set. IforderByComparator
is specified, then the query will include the given ORDER BY logic. IforderByComparator
is absent, then the query will include the default ORDER BY logic fromcom.liferay.portal.model.impl.ImageModelImpl
.- Specified by:
getImages
in interfaceImageLocalService
- Parameters:
start
- the lower bound of the range of imagesend
- the upper bound of the range of images (not inclusive)- Returns:
- the range of images
-
getImagesBySize
- Specified by:
getImagesBySize
in interfaceImageLocalService
-
getImagesCount
public int getImagesCount()Returns the number of images.- Specified by:
getImagesCount
in interfaceImageLocalService
- Returns:
- the number of images
-
getIndexableActionableDynamicQuery
- Specified by:
getIndexableActionableDynamicQuery
in interfaceImageLocalService
-
getOSGiServiceIdentifier
Returns the OSGi service identifier.- Specified by:
getOSGiServiceIdentifier
in interfaceImageLocalService
- Returns:
- the OSGi service identifier
-
getPersistedModel
- Specified by:
getPersistedModel
in interfaceImageLocalService
- Specified by:
getPersistedModel
in interfacePersistedModelLocalService
- Throws:
PortalException
PortalException
-
moveImage
- Specified by:
moveImage
in interfaceImageLocalService
- Throws:
PortalException
-
updateImage
Updates the image in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.Important: Inspect ImageLocalServiceImpl for overloaded versions of the method. If provided, use these entry points to the API, as the implementation logic may require the additional parameters defined there.
- Specified by:
updateImage
in interfaceImageLocalService
- Parameters:
image
- the image- Returns:
- the image that was updated
-
updateImage
Deprecated.As of Cavanaugh (7.4.x), replaced byupdateImage(long, long, byte[])
- Specified by:
updateImage
in interfaceImageLocalService
- Throws:
PortalException
-
updateImage
@Deprecated public Image updateImage(long imageId, byte[] bytes, String type, int height, int width, int size) throws PortalException Deprecated.As of Cavanaugh (7.4.x), replaced byupdateImage(long, long, byte[], String, int, int, int)
- Specified by:
updateImage
in interfaceImageLocalService
- Throws:
PortalException
-
updateImage
Deprecated.As of Cavanaugh (7.4.x), replaced byupdateImage(long, long, File)
- Specified by:
updateImage
in interfaceImageLocalService
- Throws:
PortalException
-
updateImage
Deprecated.As of Cavanaugh (7.4.x), replaced byupdateImage(long, long, InputStream)
- Specified by:
updateImage
in interfaceImageLocalService
- Throws:
PortalException
-
updateImage
@Deprecated public Image updateImage(long imageId, InputStream inputStream, boolean cleanUpStream) throws PortalException Deprecated.As of Cavanaugh (7.4.x), replaced byupdateImage(long, long, InputStream, boolean)
- Specified by:
updateImage
in interfaceImageLocalService
- Throws:
PortalException
-
updateImage
- Specified by:
updateImage
in interfaceImageLocalService
- Throws:
PortalException
-
updateImage
public Image updateImage(long companyId, long imageId, byte[] bytes, String type, int height, int width, int size) throws PortalException - Specified by:
updateImage
in interfaceImageLocalService
- Throws:
PortalException
-
updateImage
- Specified by:
updateImage
in interfaceImageLocalService
- Throws:
PortalException
-
updateImage
public Image updateImage(long companyId, long imageId, InputStream inputStream) throws PortalException - Specified by:
updateImage
in interfaceImageLocalService
- Throws:
PortalException
-
updateImage
public Image updateImage(long companyId, long imageId, InputStream inputStream, boolean cleanUpStream) throws PortalException - Specified by:
updateImage
in interfaceImageLocalService
- Throws:
PortalException
-
getBasePersistence
- Specified by:
getBasePersistence
in interfacePersistedModelLocalService
-
getCTPersistence
- Specified by:
getCTPersistence
in interfaceCTService<Image>
- Specified by:
getCTPersistence
in interfaceImageLocalService
-
getModelClass
- Specified by:
getModelClass
in interfaceCTService<Image>
- Specified by:
getModelClass
in interfaceImageLocalService
-
updateWithUnsafeFunction
public <R,E extends Throwable> R updateWithUnsafeFunction(com.liferay.petra.function.UnsafeFunction<CTPersistence<Image>, R, throws EE> updateUnsafeFunction) - Specified by:
updateWithUnsafeFunction
in interfaceCTService<Image>
- Specified by:
updateWithUnsafeFunction
in interfaceImageLocalService
- Throws:
E extends Throwable
-
getWrappedService
- Specified by:
getWrappedService
in interfaceServiceWrapper<ImageLocalService>
-
setWrappedService
- Specified by:
setWrappedService
in interfaceServiceWrapper<ImageLocalService>
-
updateImage(long, long, byte[])