You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
1021 B
29 lines
1021 B
// Author: Gockner, Simon
|
|
// Created: 2020-02-12
|
|
// Copyright(c) 2020 SimonG. All Rights Reserved.
|
|
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.IO;
|
|
using System.Threading;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace GBase.Interfaces.DataHandling
|
|
{
|
|
/// <summary>
|
|
/// Interface for data readers to implement
|
|
/// </summary>
|
|
public interface IDataReader
|
|
{
|
|
/// <summary>
|
|
/// Read the data of a property
|
|
/// </summary>
|
|
/// <typeparam name="T">The <see cref="Type"/></typeparam>
|
|
/// <typeparam name="TProperty">The <see cref="Type"/> of the property</typeparam>
|
|
/// <param name="file"></param>
|
|
/// <param name="propertyName">The name of the property</param>
|
|
/// <param name="cancellationToken"></param>
|
|
/// <returns>The data of the given property, null if no data found</returns>
|
|
Task<IEnumerable<TProperty>> Read<T, TProperty>(FileStream file, string propertyName, CancellationToken cancellationToken);
|
|
}
|
|
} |