Changeset 68 for trunk/Modules


Ignore:
Timestamp:
Dec 26, 2011, 12:07:37 PM (12 years ago)
Author:
chronos
Message:
  • Upraveno: Testování varianty HTTP serveru jako přímé obsluhy přes TCP. Momentálně není odděleno generování stránek pro použití z více vláken.
  • Upraveno: Třída uchování jména počítač nyní pro převod do IPv4 používá ověření správnosti namísto přímého převodu a zahlášení výjimky.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Modules/UMainModule.pas

    r67 r68  
    4141    UserOnline: TWebOnlineUser;
    4242    FormatHTML: Boolean;
     43    NetworkAddress: string;
     44    NetworkPort: Integer;
     45    MaxConnections: Integer;
    4346    procedure LoadFromRegistry;
    4447    procedure SaveToRegistry;
     
    236239  SectionGeneral = 'General';
    237240  SectionDatabase = 'Database';
     241  SectionHTTPServer = 'HTTPServer';
    238242begin
    239243  with TIniFile.Create(ConfigFile) do
     
    249253    FormatHTML := ReadBool(SectionGeneral, 'FormatHTML', False);
    250254    Application.LogException := not ReadBool(SectionGeneral, 'ShowException', False);
     255    NetworkAddress := ReadString(SectionHTTPServer, 'NetworkAddress', 'localhost');
     256    NetworkPort := ReadInteger(SectionHTTPServer, 'NetworkPort', 80);
     257    MaxConnections := ReadInteger(SectionHTTPServer, 'MaxConnections', 10);
    251258  finally
    252259    Free;
     
    258265  SectionGeneral = 'General';
    259266  SectionDatabase = 'Database';
     267  SectionHTTPServer = 'HTTPServer';
    260268begin
    261269  with TIniFile.Create(ConfigFile) do
     
    271279    WriteBool(SectionGeneral, 'FormatHTML', FormatHTML);
    272280    WriteBool(SectionGeneral, 'ShowException', not Application.LogException);
     281    WriteString(SectionHTTPServer, 'NetworkAddress', NetworkAddress);
     282    WriteInteger(SectionHTTPServer, 'NetworkPort', NetworkPort);
     283    WriteInteger(SectionHTTPServer, 'MaxConnections', MaxConnections);
    273284  finally
    274285    Free;
Note: See TracChangeset for help on using the changeset viewer.