From 226cbebece0fb95839d0482ddf454ebd5f7aeffa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=93=E3=81=AE=E4=B8=AD=E4=BA=8C=E7=97=85=E3=81=AB?= =?UTF-8?q?=E7=88=86=E7=84=94=E3=82=92=EF=BC=81?= Date: Thu, 5 Dec 2024 14:33:54 +0800 Subject: [PATCH] add comment docs about iupac name --- .../MetaLib/Models/CrossReference/Xref.vb | 4 +- .../Massbank/MetaLib/Models/MetaInfo.vb | 37 +++++++++++++++++++ src/metadb/Massbank/MetaLib/RefMet.vb | 15 ++++++-- 3 files changed, 52 insertions(+), 4 deletions(-) diff --git a/src/metadb/Massbank/MetaLib/Models/CrossReference/Xref.vb b/src/metadb/Massbank/MetaLib/Models/CrossReference/Xref.vb index ce367eb610..72d431c444 100644 --- a/src/metadb/Massbank/MetaLib/Models/CrossReference/Xref.vb +++ b/src/metadb/Massbank/MetaLib/Models/CrossReference/Xref.vb @@ -78,8 +78,10 @@ Namespace MetaLib.CrossReference ''' ''' The database cross reference set of a specific metabolite object. - ''' (对某一个物质在数据库之间的相互引用编号) ''' + ''' + ''' (对某一个物质在数据库之间的相互引用编号) + ''' Public Class xref ''' diff --git a/src/metadb/Massbank/MetaLib/Models/MetaInfo.vb b/src/metadb/Massbank/MetaLib/Models/MetaInfo.vb index d7f83da0db..fd1b25d0f2 100644 --- a/src/metadb/Massbank/MetaLib/Models/MetaInfo.vb +++ b/src/metadb/Massbank/MetaLib/Models/MetaInfo.vb @@ -93,8 +93,32 @@ Namespace MetaLib.Models Public Property exact_mass As Double Implements IExactMassProvider.ExactMass Public Property name As String Implements ICompoundNameProvider.CommonName + + ''' + ''' IUPAC name refers to the systematic name given to a chemical compound according to the rules and + ''' guidelines established by the International Union of Pure and Applied Chemistry (IUPAC). IUPAC is + ''' an international organization that aims to advance the field of chemistry by developing standards + ''' and nomenclature for chemicals. + ''' + ''' The IUPAC name of a compound provides a unique and unambiguous identifier for that compound, which + ''' is essential for clear communication among chemists and other scientists. These names are based + ''' on a set of systematic rules that take into account the structure and composition of the compound. + ''' + ''' For example, the IUPAC name for the common sugar glucose is (2R,3S,4R,5R)-2,3,4,5,6-pentahydroxyhexanal. + ''' This name describes the specific arrangement of atoms and functional groups in the glucose molecule. + ''' + ''' IUPAC names are particularly important for complex organic compounds, where common names can be + ''' confusing or non-existent. They are widely used in scientific literature, patents, and other + ''' technical documents related to chemistry. + ''' + ''' Public Property IUPACName As String Public Property description As String + + ''' + ''' the synonym of current metabolite, multiple names in different languages maybe contains inside this data names pool + ''' + ''' Public Property synonym As String() @@ -104,6 +128,15 @@ Namespace MetaLib.Models ''' Public Property xref As xref + ''' + ''' get database cross reference id by database name + ''' + ''' + ''' the database name + ''' + ''' + ''' db_xref + ''' Default Public ReadOnly Property GetXrefId(field As String) As String Get Dim arg As xref = xref @@ -128,6 +161,10 @@ Namespace MetaLib.Models End Get End Property + ''' + ''' display the name for debug view + ''' + ''' Public Overrides Function ToString() As String Return name diff --git a/src/metadb/Massbank/MetaLib/RefMet.vb b/src/metadb/Massbank/MetaLib/RefMet.vb index a696d00f55..040cbcfef6 100644 --- a/src/metadb/Massbank/MetaLib/RefMet.vb +++ b/src/metadb/Massbank/MetaLib/RefMet.vb @@ -99,16 +99,21 @@ Namespace MetaLib ''' Some notes pertaining To different metabolite classes are outlined below. ''' Public Class RefMet : Implements IReadOnlyId, IExactMassProvider, ICompoundNameProvider, IFormulaProvider, INamedValue - + Public Property refmet_id As String Public Property refmet_name As String Implements IReadOnlyId.Identity, ICompoundNameProvider.CommonName, INamedValue.Key Public Property super_class As String Public Property main_class As String Public Property sub_class As String Public Property formula As String Implements IFormulaProvider.Formula Public Property exactmass As Double Implements IExactMassProvider.ExactMass + Public Property pubchem_cid As String + Public Property chebi_id As String + Public Property hmdb_id As String + Public Property lipidmaps_id As String + Public Property kegg_id As String + Public Property inchi_key As String Public Property smiles As String - Public Property pubchem_cid As String Public Overrides Function ToString() As String Return refmet_name @@ -117,7 +122,11 @@ Namespace MetaLib Public Function CreateReference() As xref Return New xref With { .pubchem = pubchem_cid, - .SMILES = smiles + .SMILES = smiles, + .chebi = "ChEBI:" & chebi_id, + .HMDB = hmdb_id, + .lipidmaps = lipidmaps_id, + .KEGG = kegg_id } End Function