gen-jhipster
Version:
VHipster - Spring Boot + Angular/React/Vue in one handy generator
42 lines (41 loc) • 1.29 kB
TypeScript
import type CoreGenerator from '../../base-core/index.ts';
import type { NeedleCallback } from '../../base-core/support/needles.ts';
export type ApplicationPropertiesNeedles = {
property?: string;
propertyGetter?: string;
propertyClass?: string;
};
/**
* Insert content into ApplicationProperties class
* @example
* insertContentIntoApplicationProperties.call(generator, application, {
* property: 'private final bar = new Bar();',
* propertyGetter: `
* public getBar() {
* return bar;
* }`,
* propertyClass: `
* public static class Async {
* private String foo = "default";
* }`,
* })
* @example
* generator.editFile(
* 'ApplicationProperties.java',
* insertContentIntoApplicationProperties({
* property: 'private final bar = new Bar();',
* propertyGetter: `
* public getBar() {
* return bar;
* }`,
* propertyClass: `
* public static class Async {
* private String foo = "default";
* }`,
* });
* );
*/
export declare function insertContentIntoApplicationProperties(needles: ApplicationPropertiesNeedles): NeedleCallback;
export declare function insertContentIntoApplicationProperties(this: CoreGenerator, application: {
javaPackageSrcDir: string;
}, needles: ApplicationPropertiesNeedles): NeedleCallback;