2using System.Threading.Tasks;
13 internal class ReferenceLoader :
IDatabaseIteration<PersistedGeoSpatialObjectReference>
15 private readonly GeoSpatialComponent component;
22 public ReferenceLoader(GeoSpatialComponent Component)
24 this.component = Component;
30 public Task StartDatabase() => Task.CompletedTask;
35 public async Task EndDatabase()
37 if (!(this.expired is
null))
45 public Task StartCollection(
string CollectionName) => Task.CompletedTask;
50 public Task EndCollection() => Task.CompletedTask;
57 public Task
ProcessObject(PersistedGeoSpatialObjectReference Object)
59 if (Object.Expires.HasValue && Object.Expires.Value <= DateTime.Now.AddMinutes(1))
62 this.expired.
Add(Object);
65 this.component.Loaded(Object);
67 return Task.CompletedTask;
75 public Task IncompatibleObject(
object ObjectId) => Task.CompletedTask;
81 public Task ReportException(Exception Exception)
84 return Task.CompletedTask;
Static class managing the application event log. Applications and services log events on this static ...
static void Exception(Exception Exception, string Object, string Actor, string EventId, EventLevel Level, string Facility, string Module, params KeyValuePair< string, object >[] Tags)
Logs an exception. Event type will be determined by the severity of the exception.
Static interface for database persistence. In order to work, a database provider has to be assigned t...
static async Task Delete(object Object)
Deletes an object in the database.
A chunked list is a linked list of chunks of objects of type T .
void Add(T Item)
Adds an item to the collection.
Interface for iterations of database contents.
Task ProcessObject(T Object)
Is called when an object is processed.