/***************************************************************************** # Copyright (C) 1994-2008 by David Gordon. # All rights reserved. # # This software is part of a beta-test version of the Consed/Autofinish # package. It should not be redistributed or # used for any commercial purpose, including commercially funded # sequencing, without written permission from the author and the # University of Washington. # # This software is provided ``AS IS'' and any express or implied # warranties, including, but not limited to, the implied warranties of # merchantability and fitness for a particular purpose, are disclaimed. # In no event shall the authors or the University of Washington be # liable for any direct, indirect, incidental, special, exemplary, or # consequential damages (including, but not limited to, procurement of # substitute goods or services; loss of use, data, or profits; or # business interruption) however caused and on any theory of liability, # whether in contract, strict liability, or tort (including negligence # or otherwise) arising in any way out of the use of this software, even # if advised of the possibility of such damage. # # Building Consed from source is error prone and not simple which is # why I provide executables. Due to time limitations I cannot # provide any assistance in building Consed. Even if you do not # modify the source, you may introduce errors due to using a # different version of the compiler, a different version of motif, # different versions of other libraries than I used, etc. For this # reason, if you discover Consed bugs, I can only offer help with # those bugs if you first reproduce those bugs with an executable # provided by me--not an executable you have built. # # Modifying Consed is also difficult. Although Consed is modular, # some modules are used by many other modules. Thus making a change # in one place can have unforeseen effects on many other features. # It may takes months for you to notice these other side-effects # which may not seen connected at all. It is not feasable for me to # provide help with modifying Consed sources because of the # potentially huge amount of time involved. # #*****************************************************************************/ #ifndef CONSEDPARAMETERS_INCLUDED #define CONSEDPARAMETERS_INCLUDED #include "rwcstring.h" #include "rwtvalorderedvector.h" #include "sysdepend.h" #include "filename.h" #include "consedResources.h" #include #include "mbtPtrOrderedVector.h" #include "restrictionEnzyme.h" #include "assemblyViewTagTypeAndLine.h" #include "mbtValOrderedVectorOfRWCString.h" #include #include "whatIsRunning.h" class pickPCRPrimers; class library; class listOfLibraries; static const int nDontShowProteinTranslation = 0; static const int nShowProteinTranslationTopStrand = 1; static const int nShowProteinTranslationBottomStrand = -1; // static const int nAutofinishIsRunning = 1; // static const int nConsedIsRunning = 2; // static const int nAddReadsToAceFileIsRunning = 3; // static const int nAutoPCRAmplifyIsRunning = 4; // static const int nAutoEditIsRunning = 5; // static const int nAutoReportIsRunning = 6; // static const int nPrintSingleSignalIsRunning = 7; // static const int nAddReadsWithExistingAlignmentsIsRunning = 8; #define pCP consedParameters::pGetConsedParameters() class consedParameters { public: consedParameters( consedResources* pRes ); // this member function provides read access to the // sole instance // this is used just to get a bunch of space to save and // retrieve saved parameters consedParameters(); static consedParameters* pGetConsedParameters() { return pGlobalConsedParameters_; } void processDoNotFinishTagTypes(); void processDoNotExtendTagTypes(); void postProcessing(); void postProcessingAfterTagTypes(); RWCString soGetDocumentation(); void setDocumentation(); void setParametersForSequencingPrimersNotPCRPrimers( const bool bSequencingNotPCR ); void copyPrimerPickingParametersToSelf( consedParameters* pCPSource ); void makeListOfRestrictionEnzymes(); void readFileToOrderReadsInAlignedReadsWindow(); // data members that are not resources or not standard resources public: RWCString soCommandLine_; bool bWarnUserAboutOverstrikingWithUppercase_; bool bErrorMessageDisplayedAtStartup_; int nAutoFinishLastUsedPrimerNumber_; bool bOKToUseGui_; int nWhatIsRunning_; bool bReadOnly_; bool bCreateSocketToControlConsed_; int nCreateSocketToControlConsedOnThisLocalPort_; int nSocketToControlConsed_; int nSocketSuccessfullyCreatedOnThisLocalPort_; int nShowProteinTranslation_; // top strand, bottom strand, or not at all int nAutoFinishNumberOfCloningSitesFound_; RWCString soSavedReadListOptions_; bool bWillDoExperiments_; int nLastUsedExpID_; int nAutoFinishForwardReverseCalculatedAverageInsertSize_; int nAutoFinishAverageInsertSizeToUse_; int nPrimersALittleLessThanAverageInsertSizeOfASubcloneToUse_; RWTValOrderedVector aAutoFinishTagsToNotFinish_; RWTValOrderedVector aAutoFinishTagsToNotExtend_; FileName filAutoFinishFilenamesFile_; FileName filAutoFinishReversesSummary_; FileName filAutoFinishForwardsSummary_; FileName filAutoFinishCustomPrimersSummary_; FileName filAutoFinishSortedSummary_; FileName filAutoFinishFullOutput_; FileName filAutoFinishCustomNavigation_; FileName filAutoFinishMinilibrariesSummary_; FILE* pAutoFinishFilenamesFile_; FILE* pAutoFinishReversesSummary_; FILE* pAutoFinishForwardsSummary_; FILE* pAutoFinishCustomPrimersSummary_; FILE* pAutoFinishSortedSummary_; // why do I have both of the below? One is pAO and the other pFILE // pFILE is set to stdout for consed and thus the same code can be // used for both consed and autoEdit, autofinish, etc. I still don't // understand, however, why both are needed. (DG, 11/2002) FILE* pAutoFinishFullOutput_; FILE* pOutputForConsedOrAutoFinish_; FILE* pAutoFinishCustomNavigation_; FILE* pAutoFinishMinilibrariesSummary_; RWCString soDocumentation_; double dAutoFinishMinNumberOfErrorsFixedByAnExpToUse_; FileName filFileOfPhdFiles_; // this is for -fileOfPhdFiles command line argument FileName filNewFileOfPhdFilesFullPath_; FileName filFileOfPhdFilesCurrentlyBeingRead_; bool bTerminateAfterStartup_; RWTValOrderedVector aUserDefinedKeys_; RWTValOrderedVector aProgramsForUserDefinedKeys_; RWTValOrderedVector aArgumentsToPassToUserDefinedPrograms_; RWTValOrderedVector aTagsToApplyWithUserDefinedKeys_; pickPCRPrimers* pPickPCRPrimers_; bool bReadyToPickSecondPCRPrimer_; int nPrimersMinimumLengthOfAPrimerToUse_; int nPrimersMaximumLengthOfAPrimerToUse_; int nPrimersMinMeltingTempToUse_; int nPrimersMaxMeltingTempToUse_; int nPrimersWindowSizeInLookingToUse_; int nPrimersMaxMatchElsewhereScoreToUse_; library* pDefaultLibrary_; listOfLibraries* pListOfLibraries_; int nPhdFilesRead_; mbtPtrOrderedVector aRestrictionEnzymes_; RWTValOrderedVector aCommonRestrictionEnzymes_; bool bNeedToSetContigTemplateArrays_; char cFindRestrictionEnzymeSitesLastUsedWholeCloneOrPartOfCloneOrWholeContig_; RWCString soFindRestrictionEnzymeSitesLastUsedUserEnteredContigMap_; int nFindRestrictionEnzymeSitesLastUsedStartUnpaddedConsPos_; int nFindRestrictionEnzymeSitesLastUsedEndUnpaddedConsPos_; RWCString soFindRestrictionEnzymeSitesLastUsedContigAbbreviatedName_; enum { cDELETE_READS = 'd', cPUT_EACH_READ_IN_ITS_OWN_CONTIG = 'p' }; char cRemoveReadsLastUsedDeleteOrJustPutInOwnContig_; RWTValOrderedVector aListOfContigNamesForMiniassembly_; bool bWarnUserAboutAmbiguityCodes_; FILE* pDebugFile_; mbtPtrOrderedVector aAssemblyViewDisplayTheseTagTypes_; RWCString soAssemblyViewContigsToShow_; RWTPtrOrderedVector aShowReadsInAlignedReadsWindowOrderGivenByFile_; mbtValOrderedVectorOfRWCString aAutoReportPatternsOfReadsToIgnore_; bool bAllowTimestampMismatch_; time_t myTime_; int nNumberOfStartupErrors_; bool bLimitNumberOfErrorsReported_; bool bPrintInFigureOutContigOrderAndOrientation_; RWCString soDateTimeDotInMiddle_; // data members that are also resources: public: