예제 #1
0
def componentinfo(type, category=None, supplier=None):
    from mcni._find_component import find
    type, category, supplier = find(type, category=category, supplier=supplier)
    from mcni import componentinfo
    return componentinfo(type=type, category=category, supplier=supplier)
예제 #2
0
 def test(self):
     'mcni: component factory'
     from mcni import componentfactory, componentinfo
     print 'mcni, sources, MonochromaticSource',  componentfactory( 'sources', 'MonochromaticSource'), componentinfo( 'sources', 'MonochromaticSource' )
     print 'mcni, sources, MonochromaticSource',  componentfactory( 'sources', 'MonochromaticSource', 'mcni'), componentinfo( 'sources', 'MonochromaticSource', 'mcni' )
     print 'mcstas2, sources, Source_simple',  componentfactory( 'sources', 'Source_simple', 'mcstas2'), componentinfo( 'sources', 'Source_simple', 'mcstas2' )
     return
예제 #3
0
 def test(self):
     'mcni: component factory'
     print 'mcni, sources, MonochromaticSource',  componentfactory( 'sources', 'MonochromaticSource'), componentinfo( 'sources', 'MonochromaticSource' )
     print 'mcni, sources, MonochromaticSource',  componentfactory( 'sources', 'MonochromaticSource', 'mcni'), componentinfo( 'sources', 'MonochromaticSource', 'mcni' )
     return
예제 #4
0
 def test2(self):
     'mcni: component factory for mcstas components'
     import mcstas2
     print 'mcstas2, sources, Source_simple',  componentfactory( 'sources', 'Source_simple', 'mcstas2'), componentinfo( 'sources', 'Source_simple', 'mcstas2' )
     return
예제 #5
0
파일: __init__.py 프로젝트: mcvine/mcvine
def componentinfo(type, category=None, supplier=None):
    from mcni._find_component import find
    type, category, supplier = find(type, category=category, supplier=supplier)
    from mcni import componentinfo
    return  componentinfo(type=type, category=category, supplier=supplier)