# ItemList:
include("EventAthenaPool/EventAthenaPoolItemList_joboptions.py")
include(
    "AthenaPoolTestAthenaPool/AthenaPoolTestAthenaPoolItemList_joboptions.py")

printfunc(fullItemList)

from AthenaPoolCnvSvc.WriteAthenaPool import AthenaPoolOutputStream
Stream3 = AthenaPoolOutputStream("Stream3", noTag=True)

# Run OutputStream as an algorithm
topSequence += AthenaPoolOutputStream("Stream3", noTag=True)
# Must make sure that no OutStream's have been declared
theApp.OutStream = []
# Stream's output file
Stream3.WritingTool = "AthenaOutputStreamTool"
Stream3.OutputFile = "SimplePoolFile3.root"
# List of DO's to write out
#Stream1.ItemList   += fullItemList
Stream3.ItemList += ["EventInfo#*"]
# Write out only a new set of cols 1,2,3, and matrix
Stream3.ItemList += ["IAthenaPoolTestCollection#AthenaPoolTestCollection_1"]
Stream3.ItemList += ["IAthenaPoolTestCollection#AthenaPoolTestCollection_2"]
Stream3.ItemList += ["IAthenaPoolTestCollection#AthenaPoolTestCollection_3"]
Stream3.ItemList += ["AthenaPoolTestMatrix#*"]

printfunc(Stream3.ItemList)

# Change output file catalog to avoid collisions.
from PoolSvc import PoolSvcConf
PoolSvc = PoolSvcConf.PoolSvc()
    signalStream.ItemList += ["LArTTL1Container#*"]
    signalStream.ItemList += ["TileTTL1Container#*"]
    signalStream.ItemList += [
        "ROIB::RoIBResult#*", "MuCTPI_RDO#*", "CTP_RDO#*",
        "DataVector<LVL1::TriggerTower>#*", "DataVector<LVL1::CPMTower>#*",
        "DataVector<LVL1::JetElement>#*", "DataVector<LVL1::CPMHits>#*",
        "DataVector<LVL1::CPMRoI>#*", "DataVector<LVL1::CMMCPHits>#*",
        "DataVector<LVL1::CMMJetHits>#*", "DataVector<LVL1::CMMEtSums>#*",
        "DataVector<LVL1::JEMHits>#*", "DataVector<LVL1::JEMRoI>#*",
        "DataVector<LVL1::JEMEtSums>#*", "LVL1::CMMRoI#*"
    ]

#options for writing the MetaData into the output file
MetaDataStore = ServiceMgr.MetaDataStore
from AthenaPoolCnvSvc.WriteAthenaPool import AthenaPoolOutputStream
StreamRDO_MC_FH = AthenaPoolOutputStream("StreamRDO_MC_FH")
from AthenaCommon.AthenaCommonFlags import jobproperties
StreamRDO_MC_FH.OutputFile = "ROOTTREE:" + SignalCollection
StreamRDO_MC_FH.Store = MetaDataStore
StreamRDO_MC_FH.WriteOnExecute = False
StreamRDO_MC_FH.WriteOnFinalize = True
# Write all IOV meta data containers
StreamRDO_MC_FH.ItemList += ["IOVMetaDataContainer#*"]
StreamRDO_MC_FH.ItemList += ["LumiBlockCollection#*"]

from OutputStreamAthenaPool.OutputStreamAthenaPoolConf import AthenaPoolOutputStreamTool
StreamRDO_MC_FHTool = AthenaPoolOutputStreamTool("StreamRDO_MC_FHTool")
StreamRDO_MC_FHTool.OutputCollection = "MetaDataHdr"
StreamRDO_MC_FHTool.PoolContainerPrefix = "MetaData"
StreamRDO_MC_FH.WritingTool = StreamRDO_MC_FHTool
include("EventAthenaPool/EventAthenaPoolItemList_joboptions.py")
include(
    "AthenaPoolTestAthenaPool/AthenaPoolTestAthenaPoolItemList_joboptions.py")

print fullItemList

from AthenaPoolCnvSvc.WriteAthenaPool import AthenaPoolOutputStream

Stream1 = AthenaPoolOutputStream("Stream1")

# Run OutputStream as an algorithm
topSequence += AthenaPoolOutputStream("Stream1")
# Must make sure that no OutStream's have been declared
theApp.OutStream = []
# Stream's output file
Stream1.WritingTool = "AthenaPoolOutputStreamTool"
Stream1.OutputFile = "SimplePoolFile1.root"
# List of DO's to write out
#Stream1.ItemList   += fullItemList
Stream1.ItemList += ["EventInfo#*"]
#Stream1.ItemList   += ["IAthenaPoolTestCollection#*"]
# Write out only a new set of cols 1,2,3, and matrix
Stream1.ItemList += ["IAthenaPoolTestCollection#AthenaPoolTestCollection_1"]
Stream1.ItemList += ["IAthenaPoolTestCollection#AthenaPoolTestCollection_2"]
Stream1.ItemList += ["IAthenaPoolTestCollection#AthenaPoolTestCollection_3"]
Stream1.ItemList += ["AthenaPoolTestMatrix#*"]

print Stream1.ItemList

#--------------------------------------------------------------
# Set output level threshold (2=DEBUG, 3=INFO, 4=WARNING, 5=ERROR, 6=FATAL )