Click or drag to resize
LevelLocation Class
Represents a location inside an IAbstractMarkupDataContainer.
Inheritance Hierarchy
SystemObject
  Sdl.FileTypeSupport.Framework.BilingualApiLevelLocation

Namespace: Sdl.FileTypeSupport.Framework.BilingualApi
Assembly: Sdl.FileTypeSupport.Framework.Core (in Sdl.FileTypeSupport.Framework.Core.dll) Version: 1.0.0.0 (1.0.2508.0)
Syntax
public class LevelLocation : ICloneable

The LevelLocation type exposes the following members.

Constructors
  NameDescription
Public methodLevelLocation
Creates an uninitialized object.
Public methodLevelLocation(LevelLocation)
Creates from the values used in another object.
Public methodLevelLocation(IAbstractMarkupDataContainer, Int32)
Creates from specific parent and index values.
Top
Properties
  NameDescription
Public propertyIndex
The index in the parent collection that defines the location. Index 0 refers to the location before the first item in the collection. The index Parent.Count indicates a location after the last item in the collection.
Public propertyIsAtEndOfParent
True if the location is valid and refers to the position after the last item in the parent
Public propertyIsAtStartOfParent
True if the location is valid and refers to the first item in the parent
Public propertyIsValid
The location is valid if the parent is set, and the index is a value within the range: 0 <= index <= Parent.Content.Count
Public propertyItemAtLocation
Returns the item with the same index in the parent collection as the Index of this location, or null if there is no item with that index (e.g. if the index indicates a position after the last item in the collection).
Public propertyParent
The container that this location refers to a position inside.
Top
Methods
  NameDescription
Public methodClone
Create a shallow clone.
Public methodEquals
Compares all properties.
(Overrides ObjectEquals(Object).)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetHashCode
Calculated from index and parent properties
(Overrides ObjectGetHashCode.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodToString
Overridden to provide more intuitive information for use in the debugger
(Overrides ObjectToString.)
Top
Remarks

The Parent property specifies the parent container, and the Index property represents the item index in the container. An index of 0 indicates a position between the first item in the parent, and an index of Parent.Count indicates a position after the last item.

If you need to refer to an item in a nested container, use a Location instead.

Since the position includes an index into the parent, if the content of the parent changes (e.g. new items are inserted, or existing ones removed or replaced), the position may no longer point to the same item.

Use a location marker instead if you need to refer to a specific location that may change as part of operations on the data.

See Also
Community
Edit

Be the first to Edit the community content of this topic.
Comments