use strict;
my $str = '"use strict"
define ->
launchOptions = (prefix) ->
options =
"#{prefix}.businessCredits.businessBudgetFacility": functionDetails: functionId : "be.kbc.businessCredits.businessBudgetFacility", mode: "create"
"#{prefix}.businessCredits.taxPrepaymentPlan": functionDetails: functionId : "be.kbc.businessCredits.taxPrepaymentPlan", mode: "create"
"#{prefix}.credits.privateCreditCardRequest.update": functionDetails: functionId : "be.kbc.credits.privateCreditCardRequest", mode: "update"
"#{prefix}.credits.homeAtOnce": functionDetails: functionId : "be.kbc.credits.homeAtOnce", mode: "createRequest"
"#{prefix}.credits.homeAtOnce.detailRequest": functionDetails: functionId : "be.kbc.credits.homeAtOnce", mode: "detailRequest"
"#{prefix}.credits.homeAtOnce.editRequest": functionDetails: functionId : "be.kbc.credits.homeAtOnce", mode: "editRequest"
"#{prefix}.credits.homeAtOnce.updateRequest": functionDetails: functionId : "be.kbc.credits.homeAtOnce", mode: "updateRequest"
"#{prefix}.credits.budgetfacilitylight": functionDetails: functionId : "be.kbc.credits.budgetFacilityLight", mode: "create"
"#{prefix}.credits.loaRequest": functionDetails: functionId : "be.kbc.credits.loaRequest", mode: "create"
"#{prefix}.credits.loaRequest.update": functionDetails: functionId : "be.kbc.credits.loaRequest", mode: "update"
"#{prefix}.doccle.doccleAccount": functionDetails: functionId : "be.kbc.doccle.doccleAccount", mode: "create"
"#{prefix}.esigning.esigning": functionDetails: functionId : "be.kbc.esigning.esigning", mode: "create"
"#{prefix}.esigning.esigning.createBundle": functionDetails: functionId : "be.kbc.esigning.esigning", mode: "createBundle"
"#{prefix}.home.dinoHomeInsurance": functionDetails: functionId : "be.kbc.home.dinoHomeInsurance", mode: "create"
"#{prefix}.home.energyRenovationAdvice": functionDetails: functionId : "be.kbc.home.era", mode: "create"
"#{prefix}.insurances.smallProducts": functionDetails: functionId : "be.kbc.insurances.smallProducts", mode: "create"
"#{prefix}.insurances.smallproducts.external": functionDetails: functionId : "be.kbc.insurances.smallProducts", mode: "create"
"#{prefix}.insurances.insurancesUpsell": functionDetails: functionId : "be.kbc.insurances.insurancesUpsell", mode: "create"
"#{prefix}.investments.buycooperativeshares": functionDetails: functionId : "be.kbc.investments.buyCooperativeShares", mode: "create"
"#{prefix}.savings.acceptSavingsAccount": functionDetails: functionId : "be.kbc.savings.acceptSavingsAccount", mode: "create"
"#{prefix}.savings.manageAccountInsurance": functionDetails: functionId : "be.kbc.savings.manageAccountInsurance", mode: "create"
"#{prefix}.savings.manageAccountInsurance.delete": functionDetails: functionId : "be.kbc.savings.manageAccountInsurance", mode: "delete"
"#{prefix}.savings.openSavingsAccount": functionDetails: functionId : "be.kbc.savings.openSavingsAccount", mode: "create"
"#{prefix}.savings.settleSavingsAccount": functionDetails: functionId : "be.kbc.savings.settleSavingsAccount", mode: "create"
"#{prefix}.payments.businessAccountRequest": functionDetails: functionId : "be.kbc.payments.businessAccountRequest", mode: "create"
"#{prefix}.payments.cardPhoto": functionDetails: functionId : "be.kbc.payments.cardPhoto", mode: "create"
"#{prefix}.payments.preaccountrequest": functionDetails: functionId : "be.kbc.payments.preAccountRequest", mode: "create"
"#{prefix}.payments.privateAccountRequest": functionDetails: functionId : "be.kbc.payments.privateAccountRequest", mode: "create"
"#{prefix}.payments.businessCreditCardRequest": functionDetails: functionId : "be.kbc.payments.businessCreditCardRequest", mode: "create"
"#{prefix}.payments.preCardRequest": functionDetails: functionId : "be.kbc.payments.preCardRequest", mode: "create"
"#{prefix}.payments.preCardRequest.createReplacement": functionDetails: functionId : "be.kbc.payments.preCardRequest", mode: "createReplacement"
"#{prefix}.vehicle.dinoCarInsurance": functionDetails: functionId : "be.kbc.vehicle.dinoCarInsurance", mode: "create"
"#{prefix}.vehicle.privateLease": functionDetails: functionId : "be.kbc.vehicle.privateLease", mode: "create"
"#{prefix}.vehicle.privateLease.update": functionDetails: functionId : "be.kbc.vehicle.privateLease", mode: "update"
# Note: the deeplinks below are for local development testing only, the won\'t be available in the pillars
# coffeelint: disable=no_backticks
`//>>includeStart("local", pragmas.local)`
options["#{prefix}.credits.genericRequest"] = functionDetails: functionId : "be.kbc.credits.genericRequest", mode: "create"
options["#{prefix}.credits.genericRequest.continue"] = functionDetails: functionId : "be.kbc.credits.genericRequest", mode: "continue"
`//>>includeEnd("local")`
return options
return launchOptions
';
my $regex = qr/^\s+\"#{prefix}\.(.+)\":/mp;
if ( $str =~ /$regex/g ) {
print "Whole match is ${^MATCH} and its start/end positions can be obtained via \$-[0] and \$+[0]\n";
# print "Capture Group 1 is $1 and its start/end positions can be obtained via \$-[1] and \$+[1]\n";
# print "Capture Group 2 is $2 ... and so on\n";
}
# ${^POSTMATCH} and ${^PREMATCH} are also available with the use of '/p'
# Named capture groups can be called via $+{name}
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for Perl, please visit: http://perldoc.perl.org/perlre.html