Esempio n. 1
0
 public NavItem(string title, string uri, NavType navType, bool isDefault)
 {
     Title     = title;
     Uri       = uri;
     Type      = navType;
     IsDefault = isDefault;
 }
Esempio n. 2
0
        public static bool Save(SPWeb web, string fileContent, NavType navType)
        {
            bool flag = false;

            try
            {
                SPList settingList = SPContext.Current.Web.Lists[""];//SPMIPUtility.CheckSettingList("SPMIPSetting");
                byte[] bytes       = Encoding.UTF8.GetBytes(fileContent);
                web.AllowUnsafeUpdates = true;
                switch (navType)
                {
                case NavType.Top:
                {
                    settingList.RootFolder.Files.Add("TopNav.xml", bytes, true);
                    break;
                }

                case NavType.Left:
                {
                    settingList.RootFolder.Files.Add("LeftNav.xml", bytes, true);
                    break;
                }

                default:
                    settingList.RootFolder.Files.Add("TopNav.xml", bytes, true);
                    break;
                }
                flag = true;
            }
            catch (Exception exception)
            {
                throw;
            }
            return(flag);
        }
    public static Vector3 GetNavPos(int cell, NavType nav_type)
    {
        Vector3 zero = Vector3.zero;

        switch (nav_type)
        {
        case NavType.Floor:
            return(Grid.CellToPosCBC(cell, Grid.SceneLayer.Move));

        case NavType.LeftWall:
            return(Grid.CellToPosLCC(cell, Grid.SceneLayer.Move));

        case NavType.RightWall:
            return(Grid.CellToPosRCC(cell, Grid.SceneLayer.Move));

        case NavType.Ceiling:
            return(Grid.CellToPosCTC(cell, Grid.SceneLayer.Move));

        case NavType.Ladder:
            return(Grid.CellToPosCCC(cell, Grid.SceneLayer.Move));

        case NavType.Pole:
            return(Grid.CellToPosCCC(cell, Grid.SceneLayer.Move));

        case NavType.Tube:
            return(Grid.CellToPosCCC(cell, Grid.SceneLayer.Move));

        case NavType.Solid:
            return(Grid.CellToPosCCC(cell, Grid.SceneLayer.Move));

        default:
            return(Grid.CellToPosCCC(cell, Grid.SceneLayer.Move));
        }
    }
Esempio n. 4
0
    private void CheckMenuNav(GameObject button, NavType type)
    {
        switch (type)
        {
        case NavType.Next:
            if (currentPage == Mathf.CeilToInt(ScoreManager.GetLevel() / levelsPerPage + 1) - 1)
            {
                button.SetActive(false);
            }
            else
            {
                button.SetActive(true);
            }
            break;

        case NavType.Previous:
            if (currentPage == 0)
            {
                button.SetActive(false);
            }
            else
            {
                button.SetActive(true);
            }
            break;

        default:
            break;
        }
    }
Esempio n. 5
0
        /// <summary>
        /// Checks to see if this cached path is still valid. If not, the cached parameters are
        /// updated assuming that pathing is recalculated.
        /// </summary>
        /// <param name="navGrid">The navigation grid to use.</param>
        /// <param name="newCell">The starting cell.</param>
        /// <param name="navType">The navigation type currently in use.</param>
        /// <param name="abilities">The path finder's current abilities.</param>
        /// <param name="newFlags">The path finder's current flags.</param>
        /// <returns>true if cached information can be used, or false otherwise.</returns>
        public bool CheckAndUpdate(NavGrid navGrid, int newCell, NavType navType,
                                   PathFinderAbilities abilities, PathFlags newFlags)
        {
            if (navGrid == null)
            {
                throw new ArgumentNullException("navGrid");
            }
            if (abilities == null)
            {
                throw new ArgumentNullException("abilities");
            }
            bool ok = false;

            if (NavFences.AllFences.TryGetValue(navGrid.id, out NavFences fences))
            {
                long serial = fences.CurrentSerial;
                if (serial == globalSerial && flags == newFlags)
                {
                    ok = (cell == newCell) || CanNavigateReciprocal(cell, newCell, navGrid,
                                                                    navType, abilities, newFlags);
                }
                else
                {
                    // Guaranteed out of date
                    flags        = newFlags;
                    globalSerial = serial;
                }
                cell = newCell;
            }
            return(ok);
        }
Esempio n. 6
0
    public GameObject CreatePrefab()
    {
        string         id          = "ShockWorm";
        string         name        = STRINGS.CREATURES.SPECIES.SHOCKWORM.NAME;
        string         desc        = STRINGS.CREATURES.SPECIES.SHOCKWORM.DESC;
        float          mass        = 50f;
        KAnimFile      anim        = Assets.GetAnim("shockworm_kanim");
        string         initialAnim = "idle";
        EffectorValues tIER        = DECOR.BONUS.TIER0;
        GameObject     gameObject  = EntityTemplates.CreatePlacedEntity(id, name, desc, mass, anim, initialAnim, Grid.SceneLayer.Creatures, 1, 2, tIER, default(EffectorValues), SimHashes.Creature, null, 293f);
        GameObject     template    = gameObject;

        FactionManager.FactionID faction = FactionManager.FactionID.Hostile;
        initialAnim = null;
        desc        = "FlyerNavGrid1x2";
        NavType navType = NavType.Hover;

        mass = 2f;
        name = "Meat";
        int   onDeathDropCount = 3;
        float fREEZING_        = TUNING.CREATURES.TEMPERATURE.FREEZING_1;
        float hOT_             = TUNING.CREATURES.TEMPERATURE.HOT_1;

        EntityTemplates.ExtendEntityToBasicCreature(template, faction, initialAnim, desc, navType, 32, mass, name, onDeathDropCount, true, true, fREEZING_, hOT_, TUNING.CREATURES.TEMPERATURE.FREEZING_2, TUNING.CREATURES.TEMPERATURE.HOT_2);
        gameObject.AddOrGet <LoopingSounds>();
        Weapon weapon = gameObject.AddWeapon(3f, 6f, AttackProperties.DamageType.Standard, AttackProperties.TargetType.AreaOfEffect, 10, 4f);

        weapon.AddEffect("WasAttacked", 1f);
        SoundEventVolumeCache.instance.AddVolume("shockworm_kanim", "Shockworm_attack_arc", NOISE_POLLUTION.CREATURES.TIER6);
        return(gameObject);
    }
Esempio n. 7
0
    private unsafe void UpdateOffsets(int cell, CellOffset[][] table)
    {
        Debug.Assert(table.Length <= 192, $"validRowIndices[{192}] isn't big enough < {table.Length}");
        int *ptr = stackalloc int[192];
        int  num = 0;

        if (Grid.IsValidCell(cell))
        {
            for (int i = 0; i < table.Length; i++)
            {
                CellOffset[] array = table[i];
                int          cell2 = Grid.OffsetCell(cell, array[0]);
                for (int j = 0; j < navGrid.ValidNavTypes.Length; j++)
                {
                    NavType navType = navGrid.ValidNavTypes[j];
                    if (navType != NavType.Tube && navGrid.NavTable.IsValid(cell2, navType) && IsValidRow(cell, array))
                    {
                        ptr[num] = i;
                        num++;
                        break;
                    }
                }
            }
        }
        if (offsets == null || offsets.Length != num)
        {
            offsets = new CellOffset[num];
        }
        for (int k = 0; k != num; k++)
        {
            offsets[k] = table[ptr[k]][0];
        }
    }
Esempio n. 8
0
 public Number(int maxNo, NavType navType, int orderId)
 {
     this.Year    = DateTime.Now;
     this.No      = maxNo + 1;
     this.NavType = navType;
     this.OrderId = orderId;
 }
    public NavGrid(string id, Transition[] transitions, NavTypeData[] nav_type_data, CellOffset[] bounding_offsets, NavTableValidator[] validators, int update_range_x, int update_range_y, int max_links_per_cell)
    {
        this.id          = id;
        Validators       = validators;
        navTypeData      = nav_type_data;
        this.transitions = transitions;
        boundingOffsets  = bounding_offsets;
        List <NavType> list = new List <NavType>();

        updateRangeX    = update_range_x;
        updateRangeY    = update_range_y;
        maxLinksPerCell = max_links_per_cell + 1;
        for (int i = 0; i < transitions.Length; i++)
        {
            DebugUtil.Assert(i >= 0 && i <= 255);
            transitions[i].id = (byte)i;
            if (!list.Contains(transitions[i].start))
            {
                list.Add(transitions[i].start);
            }
            if (!list.Contains(transitions[i].end))
            {
                list.Add(transitions[i].end);
            }
        }
        ValidNavTypes           = list.ToArray();
        DebugViewLinkType       = new bool[ValidNavTypes.Length];
        DebugViewValidCellsType = new bool[ValidNavTypes.Length];
        NavType[] validNavTypes = ValidNavTypes;
        foreach (NavType nav_type in validNavTypes)
        {
            GetNavTypeData(nav_type);
        }
        Links                = new Link[maxLinksPerCell * Grid.CellCount];
        NavTable             = new NavTable(Grid.CellCount);
        this.transitions     = transitions;
        transitionsByNavType = new Transition[10][];
        for (int k = 0; k < 10; k++)
        {
            List <Transition> list2   = new List <Transition>();
            NavType           navType = (NavType)k;
            for (int l = 0; l < transitions.Length; l++)
            {
                Transition item = transitions[l];
                if (item.start == navType)
                {
                    list2.Add(item);
                }
            }
            transitionsByNavType[k] = list2.ToArray();
        }
        foreach (NavTableValidator navTableValidator in validators)
        {
            NavTableValidator navTableValidator2 = navTableValidator;
            navTableValidator2.onDirty = (Action <int>)Delegate.Combine(navTableValidator2.onDirty, new Action <int>(AddDirtyCell));
        }
        potentialScratchPad = new PathFinder.PotentialScratchPad(maxLinksPerCell);
        InitializeGraph();
        NavGraph = new NavGraph(Grid.CellCount, this);
    }
 private static void BuildResultPath(int path_cell, NavType path_nav_type, ref Path path)
 {
     if (path_cell != InvalidCell)
     {
         bool is_cell_in_range = false;
         Cell cell             = PathGrid.GetCell(path_cell, path_nav_type, out is_cell_in_range);
         path.Clear();
         path.cost = cell.cost;
         while (path_cell != InvalidCell)
         {
             path.AddNode(new Path.Node
             {
                 cell         = path_cell,
                 navType      = cell.navType,
                 transitionId = cell.transitionId
             });
             path_cell = cell.parent;
             if (path_cell != InvalidCell)
             {
                 cell = PathGrid.GetCell(path_cell, cell.parentNavType, out is_cell_in_range);
             }
         }
         if (path.nodes != null)
         {
             for (int i = 0; i < path.nodes.Count / 2; i++)
             {
                 Path.Node value = path.nodes[i];
                 path.nodes[i] = path.nodes[path.nodes.Count - i - 1];
                 path.nodes[path.nodes.Count - i - 1] = value;
             }
         }
     }
 }
        private static HashedString CustomIdleAnim_Drecko(IdleStates.Instance smi, ref HashedString pre_anim)
        {
            CellOffset offset         = new CellOffset(0, -1);
            bool       facing         = smi.GetComponent <Facing>().GetFacing();
            NavType    currentNavType = smi.GetComponent <Navigator>().CurrentNavType;

            if (currentNavType != NavType.Floor)
            {
                if (currentNavType == NavType.Ceiling)
                {
                    offset = (facing ? new CellOffset(1, 1) : new CellOffset(-1, 1));
                }
            }
            else
            {
                offset = (facing ? new CellOffset(1, -1) : new CellOffset(-1, -1));
            }
            HashedString result = "idle_loop";
            int          num    = Grid.OffsetCell(Grid.PosToCell(smi), offset);

            if (Grid.IsValidCell(num) && !Grid.Solid[num])
            {
                pre_anim = "idle_loop_hang_pre";
                result   = "idle_loop_hang";
            }
            return(result);
        }
Esempio n. 12
0
        /// <summary>
        /// Checks to see if the navigator can reciprocally go back and forth between a cell
        /// and another cell, checking only if they are immediately reachable.
        /// </summary>
        /// <param name="fromCell">The cell where the navigator is currently located.</param>
        /// <param name="toCell">The potential destination cell.</param>
        /// <param name="navGrid">The navigation grid to use for lookups.</param>
        /// <param name="startNavType">The navigation type to use.</param>
        /// <param name="abilities">The current navigator abilities.</param>
        /// <param name="newFlags">The flags available for this path.</param>
        /// <returns>true if navigation can be performed, both ways, or false otherwise.</returns>
        private static bool CanNavigateReciprocal(int fromCell, int toCell, NavGrid navGrid,
                                                  NavType startNavType, PathFinderAbilities abilities, PathFlags flags)
        {
            var  grid = PathFinder.PathGrid;
            bool ok   = false;
            // Find a link from this cell to the target cell
            var link = FindLinkToCell(fromCell, toCell, navGrid, startNavType);

            if (link.link != InvalidHandle)
            {
                var endNavType = link.endNavType;
                var pp         = new PathFinder.PotentialPath(toCell, endNavType, flags);
                int uwCost     = grid.GetCell(toCell, endNavType, out _).underwaterCost;
                // Can navigate there, and has a link back?
                if (abilities.TraversePath(ref pp, fromCell, startNavType, link.cost, link.
                                           transitionId, uwCost) && (link = FindLinkToCell(toCell, fromCell,
                                                                                           navGrid, endNavType)).link != InvalidHandle)
                {
                    pp.cell    = fromCell;
                    pp.navType = startNavType;
                    uwCost     = grid.GetCell(fromCell, startNavType, out _).underwaterCost;
                    ok         = abilities.TraversePath(ref pp, toCell, endNavType, link.cost,
                                                        link.transitionId, uwCost);
                }
            }
            return(ok);
        }
    public void Deserialize(IReader reader)
    {
        byte    b       = reader.ReadByte();
        NavType navType = (NavType)b;

        if (!SaveLoader.Instance.GameInfo.IsVersionOlderThan(7, 11))
        {
            int num = reader.ReadInt32();
            for (int i = 0; i < num; i++)
            {
                byte    b2    = reader.ReadByte();
                NavType key   = (NavType)b2;
                int     value = reader.ReadInt32();
                if (distanceTravelledByNavType.ContainsKey(key))
                {
                    distanceTravelledByNavType[key] = value;
                }
            }
        }
        bool flag = false;

        NavType[] validNavTypes = NavGrid.ValidNavTypes;
        foreach (NavType navType2 in validNavTypes)
        {
            if (navType2 == navType)
            {
                flag = true;
                break;
            }
        }
        if (flag)
        {
            CurrentNavType = navType;
        }
    }
Esempio n. 14
0
 public DataProxySelectionEvent(LearningSetItem compound, NavType navType, List <Kanji> kanjiChoices, List <ExampleSentence> sentenceChoices)
 {
     this.navType         = navType;
     this.compound        = compound;
     this.kanjiChoices    = kanjiChoices;
     this.sentenceChoices = sentenceChoices;
 }
Esempio n. 15
0
    public void PlayIdle(Instance smi)
    {
        KAnimControllerBase component  = smi.GetComponent <KAnimControllerBase>();
        Navigator           component2 = smi.GetComponent <Navigator>();
        NavType             nav_type   = component2.CurrentNavType;
        Facing component3 = smi.GetComponent <Facing>();

        if (component3.GetFacing())
        {
            nav_type = NavGrid.MirrorNavType(nav_type);
        }
        if (smi.def.customIdleAnim != null)
        {
            HashedString pre_anim     = HashedString.Invalid;
            HashedString hashedString = smi.def.customIdleAnim(smi, ref pre_anim);
            if (hashedString != HashedString.Invalid)
            {
                if (pre_anim != HashedString.Invalid)
                {
                    component.Play(pre_anim, KAnim.PlayMode.Once, 1f, 0f);
                }
                component.Queue(hashedString, KAnim.PlayMode.Loop, 1f, 0f);
                return;
            }
        }
        HashedString idleAnim = component2.NavGrid.GetIdleAnim(nav_type);

        component.Play(idleAnim, KAnim.PlayMode.Loop, 1f, 0f);
    }
    public static int GetAnchorCell(NavType nav_type, int cell)
    {
        int result = Grid.InvalidCell;

        if (Grid.IsValidCell(cell))
        {
            switch (nav_type)
            {
            case NavType.Floor:
                result = Grid.CellBelow(cell);
                break;

            case NavType.LeftWall:
                result = Grid.CellLeft(cell);
                break;

            case NavType.RightWall:
                result = Grid.CellRight(cell);
                break;

            case NavType.Ceiling:
                result = Grid.CellAbove(cell);
                break;

            case NavType.Solid:
                result = cell;
                break;
            }
        }
        return(result);
    }
    private static void CreateLinks(int cell, NavTable nav_table, int max_links_per_cell, NavGrid.Link[] links, NavGrid.Transition[][] transitions_by_nav_type)
    {
        int num  = cell * max_links_per_cell;
        int num2 = 0;

        for (int i = 0; i < 10; i++)
        {
            NavType nav_type           = (NavType)i;
            NavGrid.Transition[] array = transitions_by_nav_type[i];
            if (array != null && nav_table.IsValid(cell, nav_type))
            {
                NavGrid.Transition[] array2 = array;
                for (int j = 0; j < array2.Length; j++)
                {
                    NavGrid.Transition transition = array2[j];
                    int num3 = transition.IsValid(cell, nav_table);
                    if (num3 != Grid.InvalidCell)
                    {
                        links[num] = new NavGrid.Link(num3, transition.start, transition.end, transition.id, transition.cost);
                        num++;
                        num2++;
                    }
                }
            }
        }
        if (num2 >= max_links_per_cell)
        {
            Debug.LogError("Out of nav links. Need to increase maxLinksPerCell:" + max_links_per_cell);
        }
        links[num].link = Grid.InvalidCell;
    }
Esempio n. 18
0
 public Tabs(string id)
     : base("div")
 {
     this._id = id;
     EnsureClass("tabbable");
     this.Type = NavType.Tabs;
 }
Esempio n. 19
0
 public void SwitchNav(NavType nav)
 {
     if (_nav == nav)
     {
         return;
     }
     _nav = nav;
 }
 public bool IsValid(int cell, NavType nav_type = NavType.Floor)
 {
     if (Grid.IsValidCell(cell))
     {
         short num = NavTypeMasks[(uint)nav_type];
         return((num & ValidCells[cell]) != 0);
     }
     return(false);
 }
Esempio n. 21
0
 public DataProxySelectionEvent(DataProxyChoicesEvent e, NavType navType)
 {
     this.navType         = navType;
     this.sentence        = e.currentEvent.sentence;
     this.sentenceChoices = e.currentEvent.sentenceChoices;
     this.compound        = e.currentEvent.compound;
     this.compoundChoices = e.currentEvent.compoundChoices;
     this.kanji           = e.currentEvent.kanji;
     this.kanjiChoices    = e.currentEvent.kanjiChoices;
 }
 public Link(int link, NavType start_nav_type, NavType end_nav_type, byte transition_id, byte cost)
 {
     _transitionId = 0;
     _cost         = 0;
     this.link     = link;
     startNavType  = start_nav_type;
     endNavType    = end_nav_type;
     transitionId  = transition_id;
     this.cost     = cost;
 }
 public static void AddPotential(PotentialPath potential_path, int parent_cell, NavType parent_nav_type, int cost, int underwater_cost, int transition_id, PotentialList potentials, PathGrid path_grid, ref Cell cell_data)
 {
     cell_data.cost           = cost;
     cell_data.underwaterCost = (byte)Math.Min(underwater_cost, 255);
     cell_data.parent         = parent_cell;
     cell_data.navType        = potential_path.navType;
     cell_data.parentNavType  = parent_nav_type;
     cell_data.transitionId   = transition_id;
     potentials.Add(cost, potential_path);
     path_grid.SetCell(potential_path, ref cell_data);
 }
Esempio n. 24
0
 public void ChangeNav(NavType nav)
 {
     if (_monsterNav != null)
     {
         _monsterNav.SwitchNav(nav);
     }
     else
     {
         Debug.LogError("Not Found ");
     }
 }
        public static NavRef FindFirstNavAidOfType(NavType inType)
        {
            IL.DeclareLocals(false);
            Guard.NotNull(FindFirstNavAidOfTypePtr);
            NavRef result;

            IL.Push(inType);
            IL.Push(FindFirstNavAidOfTypePtr);
            IL.Emit.Calli(new StandAloneMethodSig(CallingConvention.Cdecl, typeof(NavRef), typeof(NavType)));
            IL.Pop(out result);
            return(result);
        }
 public ActiveTransition(NavGrid.Transition transition, float default_speed)
 {
     x                 = transition.x;
     y                 = transition.y;
     isLooping         = transition.isLooping;
     start             = transition.start;
     end               = transition.end;
     preAnim           = transition.preAnim;
     anim              = transition.anim;
     speed             = default_speed;
     navGridTransition = transition;
 }
    public PathFinder.Cell GetCell(int cell, NavType nav_type, out bool is_cell_in_range)
    {
        int num = OffsetCell(cell);

        is_cell_in_range = (-1 != num);
        if (!is_cell_in_range)
        {
            return(InvalidCell);
        }
        PathFinder.Cell cell2 = Cells[num * ValidNavTypes.Length + NavTypeTable[(uint)nav_type]];
        return((!IsValidSerialNo(cell2.queryId)) ? InvalidCell : cell2);
    }
 public NavTypeData GetNavTypeData(NavType nav_type)
 {
     NavTypeData[] array = navTypeData;
     for (int i = 0; i < array.Length; i++)
     {
         NavTypeData result = array[i];
         if (result.navType == nav_type)
         {
             return(result);
         }
     }
     throw new Exception("Missing nav type data for nav type:" + nav_type.ToString());
 }
 public bool HasNavTypeData(NavType nav_type)
 {
     NavTypeData[] array = this.navTypeData;
     for (int i = 0; i < array.Length; i++)
     {
         NavTypeData navTypeData = array[i];
         if (navTypeData.navType == nav_type)
         {
             return(true);
         }
     }
     return(false);
 }
        private static async Task <bool> TryClickToMove(
            Vector3 destination,
            NavType navType = NavType.Fly)
        {
            // NB: Do not 'dismount' for CtM.  We may be using it for aerial navigation, also.
            if (await SetMountState(destination, navType))
            {
                return(true);
            }

            WoWMovement.ClickToMove(destination);
            return(true);
        }
Esempio n. 31
0
        public RouteDto addOutdoorTransisiton(NavType type, CoordinateDto location, int floor)
        {
            string subtype = NavStackNode.TYPE_WALKING;

            switch (type)
            {
                case NavType.Walking:
                    subtype = NavStackNode.TYPE_WALKING;
                    break;
            }

            NavStackNode vert = new NavStackNode(NavStackNode.TYPE_OUTDOOR, subtype, location, floor, 0);
            navStack.Add(vert);

            return this;
        }
Esempio n. 32
0
 public Nav Style(NavType type)
 {
     switch (type)
     {
         case NavType.Tabs:
             EnsureClass("nav-tabs");
             break;
         case NavType.Pills:
             EnsureClass("nav-pills");
             break;
         case NavType.List:
             EnsureClass("nav-list");
             break;
     }
     return this;
 }
Esempio n. 33
0
 public Nav Style(NavType type)
 {
     EnsureClassRemoval("nav-tabs");
     switch (type)
     {
         case NavType.Tabs:
             EnsureClass("nav-tabs");
             break;
         case NavType.Pills:
             EnsureClass("bav-pills");
             break;
         case NavType.List:
             EnsureClass("nav-list");
             break;
         default:
             break;
     }
     return this;
 }
Esempio n. 34
0
        // --------------------------------------------------------------------------------------------------------------
        //  LoadXML
        //  -------------------------------------------------------------------------------------------------------------
        public IXPathNavigable LoadXML(String strFileLocation, NavType _navType)
        {
            switch (_navType)
            {
                case NavType.XmlDocument:
                    XmlDocument xmlDocument = new XmlDocument();
                    xmlDocument.Load(strFileLocation);
                    return (IXPathNavigable)xmlDocument;

                case NavType.XPathDocument:
                    XPathDocument xPathDocument = new XPathDocument(strFileLocation);
                    return (IXPathNavigable)xPathDocument;

                default:
                    return null;
            }
        }
Esempio n. 35
0
        public void Init(object objParam)
        {
            // Get input and transform type from attribute
            _nInputXsl = GetXslInputType(String.Empty);
            _nOutput = GetOutputType(String.Empty);

            // Get parameter info from runtime variables passed to LTM
            _fTrace = false;
            _navType = GetDocType(InitStringValue("doctype"));
            _readerType = GetReaderType(InitStringValue("readertype"));

            //This is a temporary fix to restore the baselines. Refer to Test bug #
            _strPath = Path.Combine(@"TestFiles\", FilePathUtil.GetTestDataPath(), @"XsltApiV2\");
            _httpPath = FilePathUtil.GetHttpTestDataPath() + @"/XsltApiV2/";
            _standardTests = Path.Combine(@"TestFiles\", FilePathUtil.GetHttpStandardPath() + @"/xslt10/Current/");

            return;
        }
Esempio n. 36
0
 public Tabs Style(NavType type)
 {
     this.Type = type;
     return this;
 }
Esempio n. 37
0
        public RouteDto addVerticalTransisiton(NavType type, CoordinateDto location, int floor, int toFloor)
        {
            string subtype = "";

            string direction = (floor - toFloor) > 0 ? "-down" : "-up";

            switch (type)
            {
                case NavType.Stair:
                    subtype = NavStackNode.TYPE_STAIRS;
                    break;
                case NavType.Elevator:
                    subtype = NavStackNode.TYPE_ELEVATOR;
                    break;
                case NavType.Escalator:
                    subtype = NavStackNode.TYPE_ESCALATOR;
                    break;
            }

            subtype += (floor - toFloor) > 0 ? "-down" : "-up";

            NavStackNode vert = new NavStackNode(NavStackNode.TYPE_VERTICAL, subtype, location, floor, toFloor);
            navStack.Add(vert);

            return this;
        }