Class ImagesServiceImpl
- java.lang.Object
-
- net.anotheria.asg.service.AbstractASGService
-
- net.anotheria.anosite.gen.shared.service.BasicService
-
- net.anotheria.anosite.gen.shared.service.BasicCMSService
-
- net.anotheria.anosite.gen.images.service.ImagesServiceImpl
-
- All Implemented Interfaces:
net.anotheria.anoprise.metafactory.Service,IImagesService,net.anotheria.asg.service.ASGService,net.anotheria.asg.util.listener.IModuleListener
public class ImagesServiceImpl extends BasicCMSService implements IImagesService, net.anotheria.asg.util.listener.IModuleListener
-
-
Field Summary
-
Fields inherited from class net.anotheria.anosite.gen.shared.service.BasicCMSService
MY_OWNER_ID, service
-
Fields inherited from class net.anotheria.anosite.gen.shared.service.BasicService
log
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcopyMultilingualAttributesInAllImages(String sourceLanguage, String targetLanguage)In all documents of type Image copies all multilingual fields from sourceLanguage to targetLanguage.voidcopyMultilingualAttributesInAllObjects(String sourceLanguage, String targetLanguage)Copies all multilingual fields from sourceLanguage to targetLanguage in all data objects (documents, vo) which are part of this module and managed by this serviceImagecreateImage(Image image)Creates a new Image object.List<Image>createImages(List<Image> list)Creates multiple new Image objects.voiddeleteImage(String id)Deletes a Image object by id.voiddeleteImage(Image image)Deletes a Image object.voiddeleteImages(List<Image> list)Deletes multiple Image object.voidexecuteParsingForDocument(DocumentName documentName, org.codehaus.jettison.json.JSONObject data)Save transferred document by its own type.net.anotheria.anodoc.query2.QueryResultexecuteQueryOnAllObjects(net.anotheria.anodoc.query2.DocumentQuery query)Executes a query on all data objects (documents, vo) which are part of this module and managed by this servicenet.anotheria.anodoc.query2.QueryResultexecuteQueryOnImages(net.anotheria.anodoc.query2.DocumentQuery query)Executes a query on Imagesnet.anotheria.util.xml.XMLNodeexportImagesToXML()net.anotheria.util.xml.XMLNodeexportImagesToXML(String[] languages)net.anotheria.util.xml.XMLNodeexportImagesToXML(String[] languages, List<Image> list)creates an xml element with selected contained data but only selected languages in multilingual attributesnet.anotheria.util.xml.XMLNodeexportImagesToXML(List<Image> list)Creates an xml element with selected contained data.net.anotheria.util.xml.XMLNodeexportToXML()creates an xml element with all contained data.net.anotheria.util.xml.XMLNodeexportToXML(String[] languages)creates an xml element with all contained data but only selected languages in multilingual attributes.voidfetchImage(String id, Set<String> addedDocuments, org.codehaus.jettison.json.JSONArray data)Create json object list dependencies for this Image document.ImagegetImage(String id)Returns the Image object with the specified id.List<Image>getImages()Returns all Images objects stored.List<Image>getImages(List<String> ids)Returns the Image objects with the specified ids.List<Image>getImages(List<String> ids, net.anotheria.util.sorter.SortType sortType)Returns the Image objects with the specified ids, sorted by given sorttype.List<Image>getImages(net.anotheria.util.slicer.Segment aSegment)Returns Image objects segment.List<Image>getImages(net.anotheria.util.sorter.SortType sortType)Returns all Images objects sorted by given sortType.List<Image>getImagesByProperty(String propertyName, Object value)Returns all Image objects, where property with given name equals object.List<Image>getImagesByProperty(String propertyName, Object value, net.anotheria.util.sorter.SortType sortType)Returns all Image objects, where property with given name equals object, sorted.List<Image>getImagesByProperty(net.anotheria.anodoc.query2.QueryProperty... property)Returns all Image objects, where property matches.List<Image>getImagesByProperty(net.anotheria.util.slicer.Segment aSegment, net.anotheria.anodoc.query2.QueryProperty... property)Returns Image objects segment, where property matched.List<Image>getImagesByProperty(net.anotheria.util.slicer.Segment aSegment, net.anotheria.util.sorter.SortType aSortType, net.anotheria.anodoc.query2.QueryProperty... aProperty)Returns Image objects segment, where property matched, sorted.List<Image>getImagesByProperty(net.anotheria.util.sorter.SortType sortType, net.anotheria.anodoc.query2.QueryProperty... property)Returns all Image objects, where property matches, sortedintgetImagesCount()Returns Image objects count.ImageimportImage(Image image)Imports a new Image object.List<Image>importImages(List<Image> list)Imports multiple new Image object.voidmoduleLoaded(net.anotheria.anodoc.data.Module module)ImageupdateImage(Image image)Updates a Image object.List<Image>updateImages(List<Image> list)Updates multiple Image objects.-
Methods inherited from class net.anotheria.anosite.gen.shared.service.BasicCMSService
addModuleListener, getModule, updateModule
-
Methods inherited from class net.anotheria.anosite.gen.shared.service.BasicService
getAnoAccessApplicationDataService, getAnoAccessConfigurationService, getASActionService, getASBrandService, getASCustomActionService, getASCustomDataService, getASExperimentService, getASFeatureService, getASFederatedDataService, getASGenericActionService, getASGenericDataService, getASLayoutDataService, getASResourceDataService, getASSiteConfigService, getASSiteDataService, getASUserDataService, getASWebDataService, getASWizardDataService, getImagesService
-
Methods inherited from class net.anotheria.asg.service.AbstractASGService
addServiceListener, fireObjectCreatedEvent, fireObjectDeletedEvent, fireObjectImportedEvent, fireObjectUpdatedEvent, firePersistenceChangedEvent, hasServiceListeners, removeServiceListener
-
-
-
-
Method Detail
-
moduleLoaded
public void moduleLoaded(net.anotheria.anodoc.data.Module module)
- Specified by:
moduleLoadedin interfacenet.anotheria.asg.util.listener.IModuleListener
-
getImages
public List<Image> getImages()
Description copied from interface:IImagesServiceReturns all Images objects stored.- Specified by:
getImagesin interfaceIImagesService
-
getImages
public List<Image> getImages(net.anotheria.util.sorter.SortType sortType)
Description copied from interface:IImagesServiceReturns all Images objects sorted by given sortType.- Specified by:
getImagesin interfaceIImagesService
-
getImages
public List<Image> getImages(List<String> ids)
Returns the Image objects with the specified ids.
-
getImages
public List<Image> getImages(List<String> ids, net.anotheria.util.sorter.SortType sortType)
Returns the Image objects with the specified ids, sorted by given sorttype.
-
deleteImage
public void deleteImage(Image image)
Description copied from interface:IImagesServiceDeletes a Image object.- Specified by:
deleteImagein interfaceIImagesService
-
deleteImage
public void deleteImage(String id)
Description copied from interface:IImagesServiceDeletes a Image object by id.- Specified by:
deleteImagein interfaceIImagesService
-
deleteImages
public void deleteImages(List<Image> list)
Description copied from interface:IImagesServiceDeletes multiple Image object.- Specified by:
deleteImagesin interfaceIImagesService
-
getImage
public Image getImage(String id)
Description copied from interface:IImagesServiceReturns the Image object with the specified id.- Specified by:
getImagein interfaceIImagesService
-
importImage
public Image importImage(Image image)
Description copied from interface:IImagesServiceImports a new Image object. Returns the created version.- Specified by:
importImagein interfaceIImagesService
-
importImages
public List<Image> importImages(List<Image> list)
Description copied from interface:IImagesServiceImports multiple new Image object. Returns the created versions.- Specified by:
importImagesin interfaceIImagesService
-
createImage
public Image createImage(Image image)
Description copied from interface:IImagesServiceCreates a new Image object. Returns the created version.- Specified by:
createImagein interfaceIImagesService
-
createImages
public List<Image> createImages(List<Image> list)
Description copied from interface:IImagesServiceCreates multiple new Image objects. Returns the created versions.- Specified by:
createImagesin interfaceIImagesService
-
updateImage
public Image updateImage(Image image)
Description copied from interface:IImagesServiceUpdates a Image object. Returns the updated version.- Specified by:
updateImagein interfaceIImagesService
-
updateImages
public List<Image> updateImages(List<Image> list)
Description copied from interface:IImagesServiceUpdates multiple Image objects. Returns the updated versions.- Specified by:
updateImagesin interfaceIImagesService
-
getImagesByProperty
public List<Image> getImagesByProperty(String propertyName, Object value)
Description copied from interface:IImagesServiceReturns all Image objects, where property with given name equals object.- Specified by:
getImagesByPropertyin interfaceIImagesService
-
getImagesByProperty
public List<Image> getImagesByProperty(String propertyName, Object value, net.anotheria.util.sorter.SortType sortType)
Description copied from interface:IImagesServiceReturns all Image objects, where property with given name equals object, sorted.- Specified by:
getImagesByPropertyin interfaceIImagesService
-
executeQueryOnImages
public net.anotheria.anodoc.query2.QueryResult executeQueryOnImages(net.anotheria.anodoc.query2.DocumentQuery query)
Executes a query on Images- Specified by:
executeQueryOnImagesin interfaceIImagesService
-
getImagesByProperty
public List<Image> getImagesByProperty(net.anotheria.anodoc.query2.QueryProperty... property)
Returns all Image objects, where property matches.- Specified by:
getImagesByPropertyin interfaceIImagesService
-
getImagesByProperty
public List<Image> getImagesByProperty(net.anotheria.util.sorter.SortType sortType, net.anotheria.anodoc.query2.QueryProperty... property)
Returns all Image objects, where property matches, sorted- Specified by:
getImagesByPropertyin interfaceIImagesService
-
getImagesCount
public int getImagesCount()
Returns Image objects count.- Specified by:
getImagesCountin interfaceIImagesService
-
getImages
public List<Image> getImages(net.anotheria.util.slicer.Segment aSegment)
Returns Image objects segment.- Specified by:
getImagesin interfaceIImagesService
-
getImagesByProperty
public List<Image> getImagesByProperty(net.anotheria.util.slicer.Segment aSegment, net.anotheria.anodoc.query2.QueryProperty... property)
Returns Image objects segment, where property matched.- Specified by:
getImagesByPropertyin interfaceIImagesService
-
getImagesByProperty
public List<Image> getImagesByProperty(net.anotheria.util.slicer.Segment aSegment, net.anotheria.util.sorter.SortType aSortType, net.anotheria.anodoc.query2.QueryProperty... aProperty)
Returns Image objects segment, where property matched, sorted.- Specified by:
getImagesByPropertyin interfaceIImagesService
-
fetchImage
public void fetchImage(String id, Set<String> addedDocuments, org.codehaus.jettison.json.JSONArray data) throws ImagesServiceException
Description copied from interface:IImagesServiceCreate json object list dependencies for this Image document.- Specified by:
fetchImagein interfaceIImagesService- Throws:
ImagesServiceException
-
copyMultilingualAttributesInAllImages
public void copyMultilingualAttributesInAllImages(String sourceLanguage, String targetLanguage)
Description copied from interface:IImagesServiceIn all documents of type Image copies all multilingual fields from sourceLanguage to targetLanguage.- Specified by:
copyMultilingualAttributesInAllImagesin interfaceIImagesService
-
executeParsingForDocument
public void executeParsingForDocument(DocumentName documentName, org.codehaus.jettison.json.JSONObject data) throws ImagesServiceException
Description copied from interface:IImagesServiceSave transferred document by its own type.- Specified by:
executeParsingForDocumentin interfaceIImagesService- Throws:
ImagesServiceException
-
copyMultilingualAttributesInAllObjects
public void copyMultilingualAttributesInAllObjects(String sourceLanguage, String targetLanguage)
Copies all multilingual fields from sourceLanguage to targetLanguage in all data objects (documents, vo) which are part of this module and managed by this service- Specified by:
copyMultilingualAttributesInAllObjectsin interfaceIImagesService
-
executeQueryOnAllObjects
public net.anotheria.anodoc.query2.QueryResult executeQueryOnAllObjects(net.anotheria.anodoc.query2.DocumentQuery query)
Executes a query on all data objects (documents, vo) which are part of this module and managed by this service- Specified by:
executeQueryOnAllObjectsin interfaceIImagesService
-
exportImagesToXML
public net.anotheria.util.xml.XMLNode exportImagesToXML()
-
exportImagesToXML
public net.anotheria.util.xml.XMLNode exportImagesToXML(List<Image> list)
Description copied from interface:IImagesServiceCreates an xml element with selected contained data.- Specified by:
exportImagesToXMLin interfaceIImagesService
-
exportImagesToXML
public net.anotheria.util.xml.XMLNode exportImagesToXML(String[] languages)
-
exportImagesToXML
public net.anotheria.util.xml.XMLNode exportImagesToXML(String[] languages, List<Image> list)
Description copied from interface:IImagesServicecreates an xml element with selected contained data but only selected languages in multilingual attributes- Specified by:
exportImagesToXMLin interfaceIImagesService
-
exportToXML
public net.anotheria.util.xml.XMLNode exportToXML()
Description copied from interface:IImagesServicecreates an xml element with all contained data.- Specified by:
exportToXMLin interfaceIImagesService
-
exportToXML
public net.anotheria.util.xml.XMLNode exportToXML(String[] languages)
Description copied from interface:IImagesServicecreates an xml element with all contained data but only selected languages in multilingual attributes.- Specified by:
exportToXMLin interfaceIImagesService
-
-