go-hep.org/x/hep@v0.38.1/heppdt/heppdt.go (about) 1 // Copyright ©2017 The go-hep Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 // Package heppdt provides access to the HEP Particle Data Table. 6 package heppdt // import "go-hep.org/x/hep/heppdt" 7 8 // Name returns the name of the default particle data table 9 func Name() string { 10 return defaultTable.Name() 11 } 12 13 // Len returns the size of the default particle data table 14 func Len() int { 15 return defaultTable.Len() 16 } 17 18 // PDT returns the default particle data table content 19 func PDT() map[PID]*Particle { 20 return defaultTable.PDT() 21 } 22 23 // ParticleByID returns the particle information via particle ID 24 func ParticleByID(pid PID) *Particle { 25 return defaultTable.ParticleByID(pid) 26 } 27 28 // ParticleByName returns the particle information via particle name 29 func ParticleByName(n string) *Particle { 30 return defaultTable.ParticleByName(n) 31 }