Changeset 151 for trunk/Packages/CoolWeb/WebServer/HTTPServer.pas
- Timestamp:
- Feb 4, 2024, 3:53:52 PM (9 months ago)
- File:
-
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/Packages/CoolWeb/WebServer/HTTPServer.pas
r150 r151 1 unit UHTTPServer;1 unit HTTPServer; 2 2 3 3 interface 4 4 5 5 uses 6 Classes, SysUtils, Common, UMemoryStreamEx, UMIMEType, Synautil, Syncobjs,6 Classes, SysUtils, Common, MemoryStreamEx, MIMEType, Synautil, Syncobjs, 7 7 Generics.Collections, Generics; 8 8 … … 77 77 78 78 TRequestHandlerList = class(TObjectList<TRequestHandler>) 79 procedure Add(AName: string; AHandler: TRequestEvent);79 function AddNew(AName: string; AHandler: TRequestEvent): TRequestHandler; 80 80 function IndexOfName(AName: string): TRequestHandler; 81 81 end; … … 279 279 { TRequestHandlerList } 280 280 281 procedure TRequestHandlerList.Add(AName: string; AHandler: TRequestEvent);282 begin 283 with TRequestHandler(Items[inherited Add(TRequestHandler.Create)]) do begin284 285 286 end;281 function TRequestHandlerList.AddNew(AName: string; AHandler: TRequestEvent): TRequestHandler; 282 begin 283 Result := TRequestHandler.Create; 284 Result.Name := AName; 285 Result.Handler := AHandler; 286 Add(Result); 287 287 end; 288 288
Note:
See TracChangeset
for help on using the changeset viewer.