資源描述:
《煙草核酸管理系統(tǒng)源程序.doc》由會員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在行業(yè)資料-天天文庫。
1、煙草核酸數(shù)據(jù)庫管理系統(tǒng)源程序云南省煙草科學(xué)研究所2006-12-18源程序的前10頁ImportsSystemImportsSystem.ioImportsSystem.TextPublicClassAbitracer'解析一個(gè)abi文件'//thenextthreelinesaretheimportantpersistentdataPrivatesequenceAsStringPrivateA(),G(),C(),T(),Basecalls()AsIntegerPrivateTraceLengt
2、h,SeqLengthAsInteger'//Thisistheactualfiledata.PrivateTraceData()AsBytePrivatemaximumAsInteger=0'//thenextfourdeclarationlinescomprisethefileindexinformationPrivateMacJunkAsInteger=0'//sometimeswhenmacintoshfilesare'//FTPedinbinaryform,theyhave128byte
3、s'//ofcrappre-pendedtothem.Thisconstant'//allowsABITracetohandlethatinawaythat'//isinvisibletotheuser.PrivateSharedAbsIndexBaseAsInteger=26'//ThefilelocationoftheIndexpointerPrivateIndexBase,PLOCAsIntegerPrivateATraceStart,CTraceStart,GTraceStart,TTra
4、ceStartAsInteger'//thenextdeclarationisfortheactualfilepointersPrivateDATA9,DATA10,DATA11,DATA12,PBAS2,FWOAsInteger'PrivatestremtempfileAsString="stream"'DimBasecalls()AsIntegerDimacolorAsColor=Color.DarkGreenDimccolorAsColor=Color.BlueDimgcolorAsColo
5、r=Color.BlackDimtcolorAsColor=Color.RedDimncolorAsColor=Color.PinkDimabrushAsBrush=Brushes.BlueDimcbrushAsBrush=Brushes.RedDimgbrushAsBrush=Brushes.DarkGreenDimtbrushAsBrush=Brushes.BlackDimnbrushAsBrush=Brushes.PinkDimbackcolorAsColor=Color.WhiteDimd
6、ffontAsFont=NewFont("TimesNewRoman",10)PrivatemyRund,mydate,myDYEP,myMACH,myMODL,myBCALAsStringPubliclableAsStringPrivateerrstringPublicFunctionABITrace(ByValABIFile()AsByte)AsBooleaninitData(ABIFile)Iferrstring<>""ThenReturnFalseElseReturnTrueEndIfEn
7、dFunctionPublicFunctionABITrace(ByValABIFileAsString)AsBooleanIfABIFile=""Thenerrstring="請輸入文件!"ReturnFalseExitFunctionEndIfDimbytes()AsByteDimfsAsFileStreamDimreaderAsBinaryReaderTryfs=NewFileStream(ABIFile,FileMode.Open)reader=NewBinaryReader(fs)byt
8、es=reader.ReadBytes(fs.Length)reader.Close()fs.Close()fs=NothingCatchexAsExceptionerrstring=ex.ToStringReturnFalseExitFunctionEndTryIfIsNothing(bytes)Thenerrstring="無效文件!"ReturnFalseExitFunctionEndIferrstring=""initData(bytes)Iferrstring<>""Th