class FlinkKinesisConsumer extends RichParallelSourceFunction<T> implements CheckpointedAsynchronously<HashMap<KinesisStreamShard, SequenceNumber>>, ResultTypeQueryable<T> {

	@Override
	public HashMap<KinesisStreamShard, SequenceNumber> snapshotState(long checkpointId, long checkpointTimestamp) throws Exception {
		if (lastStateSnapshot == null) {
			LOG.debug("snapshotState() requested on not yet opened source; returning null.");
			return null;
		}

		if (fetcher == null) {
			LOG.debug("snapshotState() requested on not yet running source; returning null.");
			return null;
		}

		if (!running) {
			LOG.debug("snapshotState() called on closed source; returning null.");
			return null;
		}

		if (LOG.isDebugEnabled()) {
			LOG.debug("Snapshotting state ...");
		}

		lastStateSnapshot = fetcher.snapshotState();

		if (LOG.isDebugEnabled()) {
			LOG.debug("Snapshotted state, last processed sequence numbers: {}, checkpoint id: {}, timestamp: {}",
				lastStateSnapshot.toString(), checkpointId, checkpointTimestamp);
		}

		return lastStateSnapshot;
	}

	public  FlinkKinesisConsumer(String stream, DeserializationSchema<T> deserializer, Properties configProps);
	public  FlinkKinesisConsumer(String stream, KinesisDeserializationSchema<T> deserializer, Properties configProps);
	public  FlinkKinesisConsumer(List<String> streams, KinesisDeserializationSchema<T> deserializer, Properties configProps);

}