namespace ReCodeIt.Models;
///
/// All settings container
///
public class Settings
{
public AppSettings AppSettings { get; set; }
public RemapperSettings Remapper { get; set; }
public AutoMapperSettings AutoMapper { get; set; }
public CrossCompilerSettings CrossCompiler { get; set; }
}
///
/// These are settings for the application
///
public class AppSettings
{
public bool Debug { get; set; }
public bool SilentMode { get; set; }
public bool RenameFields { get; set; }
public bool RenameProperties { get; set; }
}
///
/// These are settings for the manual remapper
///
public class RemapperSettings
{
///
/// Path to the assembly we want to remap
///
public string AssemblyPath { get; set; }
///
/// Path including the filename and extension we want to write the changes to
///
public string OutputPath { get; set; }
///
/// Path to the mapping file
///
public string MappingPath { get; set; }
///
/// Use the projects mappings instead of a standalone file
///
public bool UseProjectMappings { get; set; }
public MappingSettings MappingSettings { get; set; }
}
///
/// These are settings for the auto mapping
///
public class AutoMapperSettings
{
///
/// Path to the assembly we want to remap
///
public string AssemblyPath { get; set; }
///
/// Path including the filename and extension we want to write the changes to
///
public string OutputPath { get; set; }
///
/// Minimum number of times a member must have this name in the assembly before considering it
/// for remapping
///
public int RequiredMatches { get; set; }
///
/// Minimum length of the field/property name in code before it will be considered for a rename
///
public int MinLengthToMatch { get; set; }
///
/// Will attempt to map types from method meta data and parameters
///
public bool SearchMethods { get; set; }
public MappingSettings MappingSettings { get; set; }
///
/// Any member name you want to ignore while iterating through the assembly
///
public List TypesToIgnore { get; set; }
///
/// The auto mapper will look for these tokens in class names and prioritize those
///
public List TokensToMatch { get; set; }
///
/// Property or fields names to ignore in the automap, these are case sanitized so case does not matter
///
public List PropertyFieldBlackList { get; set; }
///
/// method parameter names to ignore in the automap, these are case sanitized so case does not matter
///
public List MethodParamaterBlackList { get; set; }
}
///
/// These are settings for the cross compiler module
///
public class CrossCompilerSettings
{
///
/// Last Loaded Project Path
///
public string LastLoadedProject { get; set; }
///
/// Should the last active project be auto loaded
///
public bool AutoLoadLastActiveProject { get; set; }
}
///
/// These are settings that all versions of the remappers use
///
public class MappingSettings
{
///
/// Names of fields of the matched type will be renamed to the type name with approproiate convention
///
public bool RenameFields { get; set; }
///
/// Names of properties of the matched type will be renamed to the type name with approproiate convention
///
public bool RenameProperties { get; set; }
///
/// Publicize all types, methods, and properties : NOTE: Not run until after the remap has completed
///
public bool Publicize { get; set; }
///
/// Unseal all types : NOTE: Not run until after the remap has completed
///
public bool Unseal { get; set; }
}