This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cffunction name="awsurl" returntype="string" access="public" output="No"> | |
<cfargument name="Query" type="string" required="true" /> | |
<cfargument name="AWSAccessKeyId" type="string" required="true" /> | |
<cfargument name="SecretKey" type="string" required="true" /> | |
<cfargument name="Host" type="string" default="ec2.amazonaws.com" /> | |
<cfargument name="Methord" type="string" default="GET" /> | |
<cfargument name="URI" type="string" default="/" /> | |
<cfargument name="SignatureVersion" type="string" default="2" /> | |
<cfargument name="Version" type="date" default="2012-04-01" /> | |
<cfargument name="http" type="string" default="https" hint="https|http" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cfparam name="attributes.type" default="html"> | |
<cfswitch expression="#thisTag.ExecutionMode#"> | |
<cfcase value="start"> | |
</cfcase> | |
<cfdefaultcase> | |
<!--- *************************************************** ---> | |
<!--- Basic Errors ---> | |
<!--- *************************************************** ---> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cfset sns = getHttpRequestData()> | |
<!---<cfif YesNoFormat(fromSNS(cgi.REMOTE_ADDR))>---> | |
<cfset sns = DeserializeJSON(sns.content)> | |
<!---- ****************************************************************** ---> | |
<!---- if subsribe request, acccept it (remove after first use) ---> | |
<!---- ****************************************************************** ---> | |
<cfif StructKeyExists(sns,'SubscribeURL')> | |
<cfhttp charset="utf-8" method="get" resolveurl="no" url="#sns.SubscribeURL#"> | |
</cfif> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cfset sf = createobject('Java','coldfusion.server.ServiceFactory')> | |
<cfset tasks = sf.CronService.listAll()/> | |
<cfloop from="1" to="#arraylen(tasks)#" index="i"> | |
<cfset here.task = tasks[i]> | |
<cfoutput> | |
<pre> | |
<cfschedule | |
action = "update" | |
task = "#here.task.task#" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cfcomponent displayname="USP"> | |
<!--- ********************************************************************************************** ---> | |
<!--- Hint: Before start, add correct default values for arguments currently marked with xxxxxxxxxxx ---> | |
<!--- ********************************************************************************************** ---> | |
<cffunction name = "init" access= "Public" output = "No" returntype= "Any"> | |
<!--- UPS Access Settings ---> | |
<cfargument name="License" type="string" required="No" default="xxxxxxxxxxx" hint="UPS License Key" /> | |
<cfargument name="Account" type="string" required="No" default="xxxxxxxxxxx" hint="UPS Account ID" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cfset image = ImageRead(ExpandPath('images/2.jpg'))> | |
<cfset BufferedImage = ImageGetBufferedImage(image)> | |
<cfset minScale = 1> | |
<cfset maxScale = 50> | |
<cfset Gray8DetectHaarMultiScale = CreateObject('java', 'jjil.algorithm.Gray8DetectHaarMultiScale' )> | |
<cfset DetectHaar = Gray8DetectHaarMultiScale.init( | |
CreateObject('java', 'java.io.FileInputStream').init( ExpandPath('images/haar/HCSB.txt') ), | |
JavaCast('int',minScale), | |
JavaCast('int',maxScale) ) > |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cfset image = ImageRead(ExpandPath('images/2.jpg'))> | |
<cfset BufferedImage = ImageGetBufferedImage(image)> | |
<cfset minScale = 1> | |
<cfset maxScale = 50> | |
<cfset Gray8DetectHaarMultiScale = CreateObject('java', 'jjil.algorithm.Gray8DetectHaarMultiScale' )> | |
<cfset DetectHaar = Gray8DetectHaarMultiScale.init( | |
CreateObject('java', 'java.io.FileInputStream').init( ExpandPath('images/haar/HCSB.txt') ), | |
JavaCast('int',minScale), | |
JavaCast('int',maxScale) ) > |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cfset Detector = CreateObject('java', 'jviolajones.Detector',"#ExpandPath('jviolajones.jar')#,#ExpandPath('jdom.jar')#" ).init( ExpandPath('haarcascade_frontalface_alt.xml'))> | |
<cfset image = ImageRead(ExpandPath('images/2.jpg'))> | |
<cfset results = Detector.getFaces( ImageGetBufferedImage(image) , | |
JavaCast('float',2) , | |
JavaCast('float',1.25) , | |
JavaCast('float',.05) , | |
JavaCast('int',3) , | |
JavaCast('boolean',true) ) > |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!---- ************************************************************* ---> | |
<!--- Detect Faces ---> | |
<!---- ************************************************************* ---> | |
<cfset Detector = CreateObject('java', 'jviolajones.Detector',"#ExpandPath('jviolajones.jar')#,#ExpandPath('jdom.jar')#" ).init( ExpandPath('haarcascade_frontalface_alt2.xml'))> | |
<cfset image = ImageRead(ExpandPath('images/2.jpg'))> | |
<cfset results = Detector.getFaces( ImageGetBufferedImage(image) , | |
JavaCast('float',2) , | |
JavaCast('float',1.25) , | |
JavaCast('float',.06) , |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cfset Mongo = CreateObject("java","com.mongodb.MongoClient")> | |
<cffunction name="m" returntype="any"> | |
<cfargument name="value" type="any"> | |
<cfif IsJSON(arguments.value)> | |
<cfset local.retrun = CreateObject("java","com.mongodb.util.JSON").parse(arguments.value)> | |
<cfelse> | |
<cfset local.retrun = CreateObject("java","com.mongodb.util.JSON").parse( SerializeJSON(arguments.value) )> | |
</cfif> | |
<cfreturn local.retrun> |
OlderNewer