A system comprising: one or more processors coupled to a memory; and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, the one or more programs including instructions that: obtain a plurality of trees, a tree representing a syntactic structure of a method of a source code program, the tree having nodes, at least one node associated with a type and/or method invocation; perform a closed and maximal frequent subtree data mining analysis on the plurality of trees to produce one or more idioms, an idiom representing a frequently-occurring source code pattern within the plurality of trees; and utilize the idioms to facilitate source code development (414, 416); generate a plurality of pattern trees from the closed and maximal frequent subtree data mining analysis (508, 510), a pattern tree representing at least one idiom, wherein a pattern tree is indexed by a type and/or at least one method; utilize the plurality of pattern trees to generate code snippet candidates to complete a code fragment by: receiving source code of a first method; transforming the source code of the first method into a simplified tree, the simplified tree including type data and method invocations used in the first method; matching the simplified tree with one of the plurality of pattern trees, a pattern tree representing a closed and/or maximal frequent subtree mined from methods of existing source code programs, the pattern tree associated with similar type data and/or method invocations as the simplified tree; generating the code snippet from the matched pattern tree; and displaying the code snippet as a candidate to complete the first method. one or more processors coupled to a memory; and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, the one or more programs including instructions that: obtain a plurality of trees, a tree representing a syntactic structure of a method of a source code program, the tree having nodes, at least one node associated with a type and/or method invocation; perform a closed and maximal frequent subtree data mining analysis on the plurality of trees to produce one or more idioms, an idiom representing a frequently-occurring source code pattern within the plurality of trees; and utilize the idioms to facilitate source code development (414, 416); generate a plurality of pattern trees from the closed and maximal frequent subtree data mining analysis (508, 510), a pattern tree representing at least one idiom, wherein a pattern tree is indexed by a type and/or at least one method; utilize the plurality of pattern trees to generate code snippet candidates to complete a code fragment by: receiving source code of a first method; transforming the source code of the first method into a simplified tree, the simplified tree including type data and method invocations used in the first method; matching the simplified tree with one of the plurality of pattern trees, a pattern tree representing a closed and/or maximal frequent subtree mined from methods of existing source code programs, the pattern tree associated with similar type data and/or method invocations as the simplified tree; generating the code snippet from the matched pattern tree; and displaying the code snippet as a candidate to complete the first method. obtain a plurality of trees, a tree representing a syntactic structure of a method of a source code program, the tree having nodes, at least one node associated with a type and/or method invocation; perform a closed and maximal frequent subtree data mining analysis on the plurality of trees to produce one or more idioms, an idiom representing a frequently-occurring source code pattern within the plurality of trees; and utilize the idioms to facilitate source code development (414, 416); generate a plurality of pattern trees from the closed and maximal frequent subtree data mining analysis (508, 510), a pattern tree representing at least one idiom, wherein a pattern tree is indexed by a type and/or at least one method; utilize the plurality of pattern trees to generate code snippet candidates to complete a code fragment by: receiving source code of a first method; transforming the source code of the first method into a simplified tree, the simplified tree including type data and method invocations used in the first method; matching the simplified tree with one of the plurality of pattern trees, a pattern tree representing a closed and/or maximal frequent subtree mined from methods of existing source code programs, the pattern tree associated with similar type data and/or method invocations as the simplified tree; generating the code snippet from the matched pattern tree; and displaying the code snippet as a candidate to complete the first method. receiving source code of a first method; transforming the source code of the first method into a simplified tree, the simplified tree including type data and method invocations used in the first method; matching the simplified tree with one of the plurality of pattern trees, a pattern tree representing a closed and/or maximal frequent subtree mined from methods of existing source code programs, the pattern tree associated with similar type data and/or method invocations as the simplified tree; generating the code snippet from the matched pattern tree; and displaying the code snippet as a candidate to complete the first method.