Ejemplo n.º 1
0
        public static Path Build(Path basePath, String action)
        {
            PathBuilder builder = new PathBuilder
            {
                BasePath = basePath,
                Action = action,
            };

            return builder.Build();
        }
Ejemplo n.º 2
0
        public static Path Build(Path basePath, String action)
        {
            PathBuilder builder = new PathBuilder
            {
                BasePath = basePath,
                Action   = action,
            };

            return(builder.Build());
        }
Ejemplo n.º 3
0
        public static Path Build(Path basePath, String action, DateTime initialDate, DateTime finalDate, String documentType = null)
        {
            PathBuilder builder = new PathBuilder
            {
                BasePath = basePath,
                Action = action,
                InitialDate = initialDate,
                FinalDate = finalDate,
                DocumentType = documentType
            };

            return builder.Build();
        }
Ejemplo n.º 4
0
        public static Path Build(Path basePath, String action, DateTime initialDate, DateTime finalDate, String documentType = null)
        {
            PathBuilder builder = new PathBuilder
            {
                BasePath     = basePath,
                Action       = action,
                InitialDate  = initialDate,
                FinalDate    = finalDate,
                DocumentType = documentType
            };

            return(builder.Build());
        }
Ejemplo n.º 5
0
        public void TestPathBuilder2()
        {
            var builder = new PathBuilder
            {
                BasePath = PathConstants.BasePathApiPrimavera,
                InitialDate = new DateTime(2014, 5, 10),
                FinalDate = new DateTime(2015, 10, 13)
            };

            var actual = builder.Build().ToString();
            var expected = PathConstants.BasePathApiPrimavera + "?initialDate=2014-05-10&finalDate=2015-10-13";

            Assert.AreEqual(expected, actual);
        }