Package org.cyclos.impl.system
Class BankingImportHandlerImpl<IF extends ImportedFile,E extends SimpleEntity>
- java.lang.Object
-
- org.cyclos.impl.AbstractServerComponent
-
- org.cyclos.impl.AbstractNetworkedServerComponent
-
- org.cyclos.impl.BaseNetworkedHandlerImpl
-
- org.cyclos.impl.system.BaseImportHandlerImpl<IFDTO,IFD,IF,E>
-
- org.cyclos.impl.system.BaseWithFieldsImportHandlerImpl<TransactionCustomField,CustomFieldValueDTO,BankingImportedFileDTO,BankingImportedFileData,IF,E>
-
- org.cyclos.impl.system.BankingImportHandlerImpl<IF,E>
-
- All Implemented Interfaces:
ImportHandler<BankingImportedFileDTO,BankingImportedFileData,IF,E>
- Direct Known Subclasses:
PaymentImportHandlerImpl,TransferImportHandlerImpl
public abstract class BankingImportHandlerImpl<IF extends ImportedFile,E extends SimpleEntity> extends BaseWithFieldsImportHandlerImpl<TransactionCustomField,CustomFieldValueDTO,BankingImportedFileDTO,BankingImportedFileData,IF,E>
Base handler for banking imports
-
-
Field Summary
Fields Modifier and Type Field Description protected static Set<String>REQUIRED_HEADERSprotected TransactionCustomFieldServiceLocaltransactionCustomFieldServiceprotected TransactionServiceLocaltransactionService-
Fields inherited from class org.cyclos.impl.system.BaseWithFieldsImportHandlerImpl
CUSTOM_FIELD_IMPORT_PREFIX, CUSTOM_FIELD_PRIVATE_IMPORT_SUFFIX
-
Fields inherited from class org.cyclos.impl.system.BaseImportHandlerImpl
currencyService, rawEntityManagerHandler
-
Fields inherited from class org.cyclos.impl.AbstractNetworkedServerComponent
authHandler, conversionHandler, customFieldValueHandler, entityManagerHandler, groupsHandler, productsHandler, restBeanPropertyMapping, userLocatorHandler
-
Fields inherited from class org.cyclos.impl.AbstractServerComponent
accountHandler, configurationHandler, dataTranslationHandler, notificationHandler, profileFieldHandler, transactionHandler, translationHandler
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Predicate<String>getAllowedImportFieldsPredicate(IF importedFile)Returns a predicate that evaluates true for a field allowed to be importedList<String>getKeywordFields()Returns a list of field names that can be used to search for imported linesSet<String>getMissingRequiredFields(IF importedFile, List<String> headers)Return the fields that are required and are not present in the given headers.ObjectinstantiateContext()Returns an import context that will be used in the validation and processing of each import line.protected InternalAccountOwnerparseAccountOwner(String accountOwner)protected TransferTypeparseTransferType(String type)ValidatorresolveValidator(BankingImportedFileDTO dto)Returns a new validator for the import.-
Methods inherited from class org.cyclos.impl.system.BaseWithFieldsImportHandlerImpl
fieldName, getCustomFields, getCustomFieldValueDto, getCustomFieldValues, getImportFieldName, getImportFieldNames, getPrivateImportFieldName, getPrivateImportFieldNames, parseCustomFieldValue, setCustomFieldValues, setCustomFieldValues
-
Methods inherited from class org.cyclos.impl.system.BaseImportHandlerImpl
find, finishImport, getImportField, locateUser, locateUser, parseAmount, parseBoolean, parseDate, parseDateTime
-
Methods inherited from class org.cyclos.impl.AbstractNetworkedServerComponent
canManage, checkManagesUser, checkPermission, checkRelatesToUser, checkValue, clearAlreadyValidated, getBaseEntityManagerHandler, getConfiguration, getLoggedBasicUser, getLoggedUser, getProducts, getTranslatedName, getTranslatedValue, hasPermission, hasValue, inSameNetwork, inSameNetworkOrGlobal, isAdmin, isAlreadyValidated, isBroker, isGlobalAdmin, isGlobalAdminInNetwork, isGuest, isLoggedIn, isMember, isMemberOnly, isNetworkAdmin, isOperator, isRelatedToUser, isSystem, isUserManager, isUserManagerOf, message, message, permission, permission, permissionOptionalValue, permissionOptionalValue, setAlreadyValidated, toDate, toDateTime, validate
-
Methods inherited from class org.cyclos.impl.AbstractServerComponent
dataTranslationProxy, dataTranslationProxy, delete, detach, doDataTranslationProxy, find, flush, from, getApplicationContext, getFormatter, getFormatter, getFormatter, getLogger, getRemoteAddress, getSessionData, mailContentBuilder, message, message, persist, processBatch, processBatch, refresh, remove, selectFrom, subQuery, update
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.cyclos.impl.system.ImportHandler
getData, getEntityClass, getImportedFileClass, getImportType, getSearchImportedLineFields, newImportedFile, processImportedLine, validateImportedLine
-
-
-
-
Field Detail
-
transactionService
@Autowired protected TransactionServiceLocal transactionService
-
transactionCustomFieldService
@Autowired protected TransactionCustomFieldServiceLocal transactionCustomFieldService
-
-
Method Detail
-
getAllowedImportFieldsPredicate
public Predicate<String> getAllowedImportFieldsPredicate(IF importedFile)
Description copied from interface:ImportHandlerReturns a predicate that evaluates true for a field allowed to be imported
-
getKeywordFields
public List<String> getKeywordFields()
Description copied from interface:ImportHandlerReturns a list of field names that can be used to search for imported lines
-
getMissingRequiredFields
public Set<String> getMissingRequiredFields(IF importedFile, List<String> headers)
Description copied from interface:ImportHandlerReturn the fields that are required and are not present in the given headers.
-
instantiateContext
public Object instantiateContext()
Description copied from interface:ImportHandlerReturns an import context that will be used in the validation and processing of each import line.
-
resolveValidator
public Validator resolveValidator(BankingImportedFileDTO dto)
Description copied from interface:ImportHandlerReturns a new validator for the import.
-
parseAccountOwner
protected InternalAccountOwner parseAccountOwner(String accountOwner)
-
parseTransferType
protected TransferType parseTransferType(String type)
-
-