private string GenerateDescription()
        {
            // a framework name is a random markov chain that terminates in a period or after 20 words.
            IEnumerable <string> generatedDescription = descriptionGenerator.Generate();
            var description = string.Join(" ", generatedDescription.Take(20));

            return(ExtractSentence(description));
        }
Example #2
0
        private string GenerateCompany()
        {
            var generatedName = companyGenerator.Generate();
            var name          = string.Join("",
                                            generatedName.SkipWhile(c => !char.IsLetterOrDigit(c[0])).TakeWhile(c => c != "/")
                                            );

            return(name);
        }
        private string GenerateName()
        {
            // a framework name is a random markov chain that terminates in a space.
            IEnumerable <string> generatedName = nameGenerator.Generate();
            var name = string.Join("",
                                   generatedName.SkipWhile(c => !char.IsLetterOrDigit(c[0])).TakeWhile(c => c != " ")
                                   );

            return(name.IndexOf("js", StringComparison.OrdinalIgnoreCase) == -1
                ? name + ".js"
                : name);
        }