package com.hammurapi.common.extract.tests;

import java.util.Map;
import java.util.concurrent.TimeUnit;

import com.hammurapi.extract.AbstractExtractor;
import com.hammurapi.extract.Extractor;
import com.hammurapi.store.Store;
import com.hammurapi.store.local.LocalStore;

public class AccountNumberExtractor extends AbstractExtractor<Account, Integer, LocalStore<Account,Integer>> {

	public AccountNumberExtractor() {
		super(0, TimeUnit.NANOSECONDS, false, 0);
	}

	@Override
	protected Integer extractInternal(
			LocalStore<Account, Integer> context,
			Map<LocalStore<Account, Integer>, Map<Extractor<Account, ? super Integer, LocalStore<Account, Integer>>, ? super Integer>> cache,
			Account... obj) {
		return obj[0].getNumber();
	}
	
}
