Paradox Game Engine
v1.0.0 beta06
Main Page
Related Pages
Packages
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Events
Macros
Pages
ContentBase.cs
Go to the documentation of this file.
1
// Copyright (c) 2014 Silicon Studio Corp. (http://siliconstudio.co.jp)
2
// This file is distributed under GPL v3. See LICENSE.md for details.
3
using
System
;
4
5
using
SiliconStudio.Core.Reflection;
6
using
SiliconStudio.Quantum.References;
7
8
namespace
SiliconStudio.Quantum.Contents
9
{
10
/// <summary>
11
/// A base abstract implementation of the <see cref="IContent"/> interface.
12
/// </summary>
13
public
abstract
class
ContentBase
:
IContent
14
{
15
private
readonly
IReference
reference;
16
17
protected
ContentBase
(Type type,
ITypeDescriptor
descriptor,
bool
isPrimitive,
IReference
reference)
18
{
19
if
(type == null)
throw
new
ArgumentNullException(
"type"
);
20
if
(descriptor == null)
throw
new
ArgumentNullException(
"descriptor"
);
21
this.reference = reference;
22
Descriptor = descriptor;
23
Type = type;
24
IsPrimitive = isPrimitive;
25
SerializeFlags = ViewModelContentSerializeFlags.SerializeValue;
26
}
27
28
/// <inheritdoc/>
29
public
Type Type {
get
; set; }
30
31
/// <inheritdoc/>
32
public
abstract
object
Value {
get
; set; }
33
34
/// <inheritdoc/>
35
public
bool
IsPrimitive {
get
;
private
set; }
36
37
/// <inheritdoc/>
38
public
ITypeDescriptor
Descriptor {
get
;
private
set; }
39
40
/// <inheritdoc/>
41
public
bool
IsReference {
get
{
return
Reference != null; } }
42
43
/// <inheritdoc/>
44
public
IReference
Reference {
get
{
return
reference; } }
45
46
/// <inheritdoc/>
47
public
virtual
ViewModelContentState
LoadState {
get
; set; }
48
49
/// <inheritdoc/>
50
public
ViewModelContentFlags
Flags
{
get
; set; }
51
52
/// <inheritdoc/>
53
public
ViewModelContentSerializeFlags
SerializeFlags {
get
; set; }
54
55
/// <inheritdoc/>
56
public
override
string
ToString
()
57
{
58
return
"["
+ GetType().Name +
"]: "
+ Value;
59
}
60
}
61
}
SiliconStudio.Quantum.Contents.ViewModelContentFlags
ViewModelContentFlags
Definition:
ViewModelContentSerializeFlags.cs:8
SiliconStudio.Quantum.Contents.ContentBase.ToString
override string ToString()
Definition:
ContentBase.cs:56
SiliconStudio.Quantum.Contents.ContentBase
A base abstract implementation of the IContent interface.
Definition:
ContentBase.cs:13
SiliconStudio.Quantum.Contents.IContent
Content of a IModelNode.
Definition:
IContent.cs:13
SiliconStudio.Shaders.Parser.System
A system file.
SiliconStudio.Paradox.AssimpNet.Material.Flags
Flags
Enumeration of the new Assimp's flags.
Definition:
MaterialStack.cs:29
SiliconStudio.Quantum.References.IReference
Definition:
IReference.cs:7
SiliconStudio.Quantum.Contents.ViewModelContentSerializeFlags
ViewModelContentSerializeFlags
Flags applying to IContent.
Definition:
ViewModelContentSerializeFlags.cs:25
SiliconStudio.Core.Reflection.ITypeDescriptor
Provides access members of a type.
Definition:
ITypeDescriptor.cs:12
SiliconStudio.Quantum.ViewModelContentState
ViewModelContentState
Definition:
ViewModelContentState.cs:5
SiliconStudio.Quantum.Contents.ContentBase.ContentBase
ContentBase(Type type, ITypeDescriptor descriptor, bool isPrimitive, IReference reference)
Definition:
ContentBase.cs:17
sources
common
presentation
SiliconStudio.Quantum
Contents
ContentBase.cs
Generated on Sat Dec 20 2014 21:51:20 for Paradox Game Engine by
1.8.7