annotate api/Factories/DummyWarFoundryFactory.cs @ 312:3854c26073c4

Re #253: Allow multiple data files in a single zip * Rebuild file loading to start to allow multiple files in a native file
author IBBoard <dev@ibboard.co.uk>
date Sat, 26 Feb 2011 20:15:12 +0000
parents 52985d48b263
children f00a57369aaa
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
293
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
1 // This file (DummyWarFoundryFactory.cs) is a part of the IBBoard.WarFoundry.API project and is copyright 2010 IBBoard
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
2 //
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
3 // The file and the library/program it is in are licensed and distributed, without warranty, under the GNU Affero GPL license, either version 3 of the License or (at your option) any later version. Please see COPYING for more information and the full license.
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
4
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
5 using IBBoard.WarFoundry.API.Factories;
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
6 using IBBoard.WarFoundry.API.Objects;
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
7 using System.IO;
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
8 using System.Collections.Generic;
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
9
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
10 namespace IBBoard.WarFoundry.API.Factories
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
11 {
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
12 ///<summary>
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
13 ///A dummy factory for use with <see cref="WarFoundryStagedLoadingObject"/>s that implements the bare minimum of the methods but won't load anything
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
14 ///</summary>
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
15 public class DummyWarFoundryFactory : IWarFoundryFactory
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
16 {
294
52985d48b263 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents: 293
diff changeset
17 public DummyWarFoundryFactory()
52985d48b263 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents: 293
diff changeset
18 {
52985d48b263 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents: 293
diff changeset
19 //Public constructor
52985d48b263 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents: 293
diff changeset
20 }
52985d48b263 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents: 293
diff changeset
21
293
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
22 public void CompleteLoading(IWarFoundryStagedLoadObject obj)
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
23 {
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
24 obj.SetAsFullyLoaded();
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
25 }
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
26
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
27 public bool CanHandleFileFormat(FileInfo file)
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
28 {
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
29 return false;
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
30 }
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
31
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
32 public bool CanHandleFileAsRace(FileInfo file)
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
33 {
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
34 return false;
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
35 }
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
36
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
37 public bool CanHandleFileAsGameSystem(FileInfo file)
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
38 {
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
39 return false;
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
40 }
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
41
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
42 public bool CanHandleFileAsArmy(FileInfo file)
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
43 {
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
44 return false;
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
45 }
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
46
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
47 public ICollection<IWarFoundryObject> CreateObjectsFromFile(FileInfo file)
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
48 {
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
49 return new List<IWarFoundryObject>();
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
50 }
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
51 }
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
52 }
a1657c6f41a0 Re #319: WarFoundry Forge - No Factory set failure
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
53