hexsha
stringlengths
40
40
size
int64
5
1.05M
ext
stringclasses
98 values
lang
stringclasses
21 values
max_stars_repo_path
stringlengths
3
945
max_stars_repo_name
stringlengths
4
118
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
3
945
max_issues_repo_name
stringlengths
4
118
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
134k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
3
945
max_forks_repo_name
stringlengths
4
135
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
5
1.05M
avg_line_length
float64
1
1.03M
max_line_length
int64
2
1.03M
alphanum_fraction
float64
0
1
f17ddfd43146f12df36b6a41140b61acbb80351d
7,354
psm1
PowerShell
Modules/SharePointDsc/DSCResources/MSFT_SPWebAppSiteUseAndDeletion/MSFT_SPWebAppSiteUseAndDeletion.psm1
jensotto/SharePointDsc
b072ab3f00373e16c2b790d066f40fcd40d64076
[ "MIT" ]
64
2015-05-27T19:48:01.000Z
2020-11-11T22:23:31.000Z
Modules/SharePointDsc/DSCResources/MSFT_SPWebAppSiteUseAndDeletion/MSFT_SPWebAppSiteUseAndDeletion.psm1
jensotto/SharePointDsc
b072ab3f00373e16c2b790d066f40fcd40d64076
[ "MIT" ]
290
2015-05-07T15:37:49.000Z
2022-03-25T15:22:45.000Z
Modules/SharePointDsc/DSCResources/MSFT_SPWebAppSiteUseAndDeletion/MSFT_SPWebAppSiteUseAndDeletion.psm1
jensotto/SharePointDsc
b072ab3f00373e16c2b790d066f40fcd40d64076
[ "MIT" ]
112
2015-05-13T18:11:48.000Z
2021-03-05T11:40:55.000Z
function Get-TargetResource { [CmdletBinding()] [OutputType([System.Collections.Hashtable])] param ( [Parameter(Mandatory = $true)] [System.String] $WebAppUrl, [Parameter()] [System.Boolean] $SendUnusedSiteCollectionNotifications, [Parameter()] [System.UInt32] $UnusedSiteNotificationPeriod, [Parameter()] [System.Boolean] $AutomaticallyDeleteUnusedSiteCollections, [Parameter()] [ValidateRange(2,168)] [System.UInt32] $UnusedSiteNotificationsBeforeDeletion, [Parameter()] [System.Management.Automation.PSCredential] $InstallAccount ) Write-Verbose -Message "Getting web application '$WebAppUrl' site use and deletion settings" $result = Invoke-SPDSCCommand -Credential $InstallAccount ` -Arguments $PSBoundParameters ` -ScriptBlock { $params = $args[0] try { $spFarm = Get-SPFarm } catch { Write-Verbose -Message ("No local SharePoint farm was detected. Site Use and " + ` "Deletion settings will not be applied") return $null } $wa = Get-SPWebApplication -Identity $params.WebAppUrl ` -ErrorAction SilentlyContinue if ($null -eq $wa) { return $null } return @{ # Set the Site Use and Deletion settings WebAppUrl = $params.WebAppUrl SendUnusedSiteCollectionNotifications = $wa.SendUnusedSiteCollectionNotifications UnusedSiteNotificationPeriod = $wa.UnusedSiteNotificationPeriod.TotalDays AutomaticallyDeleteUnusedSiteCollections = $wa.AutomaticallyDeleteUnusedSiteCollections UnusedSiteNotificationsBeforeDeletion = $wa.UnusedSiteNotificationsBeforeDeletion InstallAccount = $params.InstallAccount } } return $result } function Set-TargetResource { [CmdletBinding()] param ( [Parameter(Mandatory = $true)] [System.String] $WebAppUrl, [Parameter()] [System.Boolean] $SendUnusedSiteCollectionNotifications, [Parameter()] [System.UInt32] $UnusedSiteNotificationPeriod, [Parameter()] [System.Boolean] $AutomaticallyDeleteUnusedSiteCollections, [Parameter()] [ValidateRange(2,168)] [System.UInt32] $UnusedSiteNotificationsBeforeDeletion, [Parameter()] [System.Management.Automation.PSCredential] $InstallAccount ) Write-Verbose -Message "Setting web application '$WebAppUrl' Site Use and Deletion settings" Invoke-SPDSCCommand -Credential $InstallAccount ` -Arguments $PSBoundParameters ` -ScriptBlock { $params = $args[0] try { $spFarm = Get-SPFarm } catch { throw ("No local SharePoint farm was detected. Site Use and Deletion settings " + ` "will not be applied") } $wa = Get-SPWebApplication -Identity $params.WebAppUrl -ErrorAction SilentlyContinue if ($null -eq $wa) { throw "Configured web application could not be found" } # Check if the specified value is in the range for the configured schedule $job = Get-SPTimerJob -Identity job-dead-site-delete -WebApplication $params.WebAppUrl if ($null -eq $job) { throw "Dead Site Delete timer job for web application $($params.WebAppUrl) could not be found" } else { # Check schedule value switch ($job.Schedule.Description) { "Daily" { if (($params.UnusedSiteNotificationsBeforeDeletion -lt 28) -or ($params.UnusedSiteNotificationsBeforeDeletion -gt 168)) { throw ("Value of UnusedSiteNotificationsBeforeDeletion has to be >28 and " + ` "<168 when the schedule is set to daily") } } "Weekly" { if (($params.UnusedSiteNotificationsBeforeDeletion -lt 4) -or ($params.UnusedSiteNotificationsBeforeDeletion -gt 24)) { throw ("Value of UnusedSiteNotificationsBeforeDeletion has to be >4 and " + ` "<24 when the schedule is set to weekly") } } "Monthly" { if (($params.UnusedSiteNotificationsBeforeDeletion -lt 2) -or ($params.UnusedSiteNotificationsBeforeDeletion -gt 6)) { throw ("Value of UnusedSiteNotificationsBeforeDeletion has to be >2 and " + ` "<6 when the schedule is set to monthly") } } } } Write-Verbose -Message "Start update" # Set the Site Use and Deletion settings if ($params.ContainsKey("SendUnusedSiteCollectionNotifications")) { $wa.SendUnusedSiteCollectionNotifications = ` $params.SendUnusedSiteCollectionNotifications } if ($params.ContainsKey("UnusedSiteNotificationPeriod")) { $timespan = New-TimeSpan -Days $params.UnusedSiteNotificationPeriod $wa.UnusedSiteNotificationPeriod = $timespan } if ($params.ContainsKey("AutomaticallyDeleteUnusedSiteCollections")) { $wa.AutomaticallyDeleteUnusedSiteCollections = ` $params.AutomaticallyDeleteUnusedSiteCollections } if ($params.ContainsKey("UnusedSiteNotificationsBeforeDeletion")) { $wa.UnusedSiteNotificationsBeforeDeletion = ` $params.UnusedSiteNotificationsBeforeDeletion } $wa.Update() } } function Test-TargetResource { [CmdletBinding()] [OutputType([System.Boolean])] param ( [Parameter(Mandatory = $true)] [System.String] $WebAppUrl, [Parameter()] [System.Boolean] $SendUnusedSiteCollectionNotifications, [Parameter()] [System.UInt32] $UnusedSiteNotificationPeriod, [Parameter()] [System.Boolean] $AutomaticallyDeleteUnusedSiteCollections, [Parameter()] [ValidateRange(2,168)] [System.UInt32] $UnusedSiteNotificationsBeforeDeletion, [Parameter()] [System.Management.Automation.PSCredential] $InstallAccount ) Write-Verbose -Message "Testing web application '$WebAppUrl' site use and deletion settings" $CurrentValues = Get-TargetResource @PSBoundParameters if ($null -eq $CurrentValues) { return $false } return Test-SPDscParameterState -CurrentValues $CurrentValues ` -DesiredValues $PSBoundParameters } Export-ModuleMember -Function *-TargetResource
31.029536
106
0.569078
afcf5e0758d0588b3319c3264063d0188c24ccfe
66,983
html
HTML
tools/gwt-2.5.0/doc/javadoc/com/google/gwt/event/dom/client/package-tree.html
adityaponnada/paco
9c8355b8bd0a98a8f20fdf81799b791e07e72e1d
[ "Apache-2.0" ]
1
2021-04-21T19:59:06.000Z
2021-04-21T19:59:06.000Z
tools/gwt-2.5.0/doc/javadoc/com/google/gwt/event/dom/client/package-tree.html
adityaponnada/paco
9c8355b8bd0a98a8f20fdf81799b791e07e72e1d
[ "Apache-2.0" ]
null
null
null
tools/gwt-2.5.0/doc/javadoc/com/google/gwt/event/dom/client/package-tree.html
adityaponnada/paco
9c8355b8bd0a98a8f20fdf81799b791e07e72e1d
[ "Apache-2.0" ]
null
null
null
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <!-- NewPage --> <html lang="en"> <head> <title>com.google.gwt.event.dom.client Class Hierarchy (Google Web Toolkit Javadoc)</title> <link rel="stylesheet" type="text/css" href="../../../../../../stylesheet.css" title="Style"> </head> <body> <script type="text/javascript"><!-- if (location.href.indexOf('is-external=true') == -1) { parent.document.title="com.google.gwt.event.dom.client Class Hierarchy (Google Web Toolkit Javadoc)"; } //--> </script> <noscript> <div>JavaScript is disabled on your browser.</div> </noscript> <!-- ========= START OF TOP NAVBAR ======= --> <div class="topNav"><a name="navbar_top"> <!-- --> </a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow"> <!-- --> </a> <ul class="navList" title="Navigation"> <li><a href="../../../../../../overview-summary.html">Overview</a></li> <li><a href="package-summary.html">Package</a></li> <li>Class</li> <li>Use</li> <li class="navBarCell1Rev">Tree</li> <li><a href="../../../../../../deprecated-list.html">Deprecated</a></li> <li><a href="../../../../../../index-all.html">Index</a></li> <li><a href="../../../../../../help-doc.html">Help</a></li> </ul> <div class="aboutLanguage"><em>GWT 2.5.0</em></div> </div> <div class="subNav"> <ul class="navList"> <li><a href="../../../../../../com/google/gwt/editor/ui/client/adapters/package-tree.html">Prev</a></li> <li><a href="../../../../../../com/google/gwt/event/logical/shared/package-tree.html">Next</a></li> </ul> <ul class="navList"> <li><a href="../../../../../../index.html?com/google/gwt/event/dom/client/package-tree.html" target="_top">Frames</a></li> <li><a href="package-tree.html" target="_top">No Frames</a></li> </ul> <ul class="navList" id="allclasses_navbar_top"> <li><a href="../../../../../../allclasses-noframe.html">All Classes</a></li> </ul> <div> <script type="text/javascript"><!-- allClassesLink = document.getElementById("allclasses_navbar_top"); if(window==top) { allClassesLink.style.display = "block"; } else { allClassesLink.style.display = "none"; } //--> </script> </div> <a name="skip-navbar_top"> <!-- --> </a></div> <!-- ========= END OF TOP NAVBAR ========= --> <div class="header"> <h1 class="title">Hierarchy For Package com.google.gwt.event.dom.client</h1> <span class="strong">Package Hierarchies:</span> <ul class="horizontal"> <li><a href="../../../../../../overview-tree.html">All Packages</a></li> </ul> </div> <div class="contentContainer"> <h2 title="Class Hierarchy">Class Hierarchy</h2> <ul> <li type="circle">java.lang.Object <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragDropEventBase.DragSupportDetector.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DragDropEventBase.DragSupportDetector</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragDropEventBase.DragSupportDetectorNo.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DragDropEventBase.DragSupportDetectorNo</span></a></li> </ul> </li> <li type="circle">com.google.web.bindery.event.shared.<a href="../../../../../../com/google/web/bindery/event/shared/Event.html" title="class in com.google.web.bindery.event.shared"><span class="strong">Event</span></a>&lt;H&gt; <ul> <li type="circle">com.google.gwt.event.shared.<a href="../../../../../../com/google/gwt/event/shared/GwtEvent.html" title="class in com.google.gwt.event.shared"><span class="strong">GwtEvent</span></a>&lt;H&gt; <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DomEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DomEvent</span></a>&lt;H&gt; (implements com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasNativeEvent.html" title="interface in com.google.gwt.event.dom.client">HasNativeEvent</a>) <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/BlurEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">BlurEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/CanPlayThroughEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">CanPlayThroughEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/ChangeEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">ChangeEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/ContextMenuEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">ContextMenuEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragDropEventBase.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DragDropEventBase</span></a>&lt;H&gt; <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragEndEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DragEndEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragEnterEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DragEnterEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DragEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragLeaveEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DragLeaveEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragOverEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DragOverEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragStartEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DragStartEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DropEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DropEvent</span></a></li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/EndedEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">EndedEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/ErrorEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">ErrorEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/FocusEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">FocusEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/GestureChangeEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">GestureChangeEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/GestureEndEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">GestureEndEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/GestureStartEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">GestureStartEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HumanInputEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">HumanInputEvent</span></a>&lt;H&gt; <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">MouseEvent</span></a>&lt;H&gt; <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/ClickEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">ClickEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DoubleClickEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DoubleClickEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseDownEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">MouseDownEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseMoveEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">MouseMoveEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseOutEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">MouseOutEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseOverEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">MouseOverEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseUpEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">MouseUpEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseWheelEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">MouseWheelEvent</span></a></li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">TouchEvent</span></a>&lt;H&gt; <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchCancelEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">TouchCancelEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchEndEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">TouchEndEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchMoveEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">TouchMoveEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchStartEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">TouchStartEvent</span></a></li> </ul> </li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/KeyEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">KeyEvent</span></a>&lt;H&gt; <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/KeyCodeEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">KeyCodeEvent</span></a>&lt;H&gt; <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/KeyDownEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">KeyDownEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/KeyUpEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">KeyUpEvent</span></a></li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/KeyPressEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">KeyPressEvent</span></a></li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/LoadEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">LoadEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/LoseCaptureEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">LoseCaptureEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/ProgressEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">ProgressEvent</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/ScrollEvent.html" title="class in com.google.gwt.event.dom.client"><span class="strong">ScrollEvent</span></a></li> </ul> </li> </ul> </li> </ul> </li> <li type="circle">com.google.web.bindery.event.shared.<a href="../../../../../../com/google/web/bindery/event/shared/Event.Type.html" title="class in com.google.web.bindery.event.shared"><span class="strong">Event.Type</span></a>&lt;H&gt; <ul> <li type="circle">com.google.gwt.event.shared.<a href="../../../../../../com/google/gwt/event/shared/GwtEvent.Type.html" title="class in com.google.gwt.event.shared"><span class="strong">GwtEvent.Type</span></a>&lt;H&gt; <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DomEvent.Type.html" title="class in com.google.gwt.event.dom.client"><span class="strong">DomEvent.Type</span></a>&lt;H&gt;</li> </ul> </li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HandlesAllFocusEvents.html" title="class in com.google.gwt.event.dom.client"><span class="strong">HandlesAllFocusEvents</span></a> (implements com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/BlurHandler.html" title="interface in com.google.gwt.event.dom.client">BlurHandler</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/FocusHandler.html" title="interface in com.google.gwt.event.dom.client">FocusHandler</a>)</li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HandlesAllKeyEvents.html" title="class in com.google.gwt.event.dom.client"><span class="strong">HandlesAllKeyEvents</span></a> (implements com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/KeyDownHandler.html" title="interface in com.google.gwt.event.dom.client">KeyDownHandler</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/KeyPressHandler.html" title="interface in com.google.gwt.event.dom.client">KeyPressHandler</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/KeyUpHandler.html" title="interface in com.google.gwt.event.dom.client">KeyUpHandler</a>)</li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HandlesAllMouseEvents.html" title="class in com.google.gwt.event.dom.client"><span class="strong">HandlesAllMouseEvents</span></a> (implements com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseDownHandler.html" title="interface in com.google.gwt.event.dom.client">MouseDownHandler</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseMoveHandler.html" title="interface in com.google.gwt.event.dom.client">MouseMoveHandler</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseOutHandler.html" title="interface in com.google.gwt.event.dom.client">MouseOutHandler</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseOverHandler.html" title="interface in com.google.gwt.event.dom.client">MouseOverHandler</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseUpHandler.html" title="interface in com.google.gwt.event.dom.client">MouseUpHandler</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseWheelHandler.html" title="interface in com.google.gwt.event.dom.client">MouseWheelHandler</a>)</li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HandlesAllTouchEvents.html" title="class in com.google.gwt.event.dom.client"><span class="strong">HandlesAllTouchEvents</span></a> (implements com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchCancelHandler.html" title="interface in com.google.gwt.event.dom.client">TouchCancelHandler</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchEndHandler.html" title="interface in com.google.gwt.event.dom.client">TouchEndHandler</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchMoveHandler.html" title="interface in com.google.gwt.event.dom.client">TouchMoveHandler</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchStartHandler.html" title="interface in com.google.gwt.event.dom.client">TouchStartHandler</a>)</li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/KeyCodes.html" title="class in com.google.gwt.event.dom.client"><span class="strong">KeyCodes</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/PrivateMap.html" title="class in com.google.gwt.event.dom.client"><span class="strong">PrivateMap</span></a>&lt;V&gt;</li> </ul> </li> </ul> <h2 title="Interface Hierarchy">Interface Hierarchy</h2> <ul> <li type="circle">com.google.gwt.event.shared.<a href="../../../../../../com/google/gwt/event/shared/EventHandler.html" title="interface in com.google.gwt.event.shared"><span class="strong">EventHandler</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/BlurHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">BlurHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/CanPlayThroughHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">CanPlayThroughHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/ChangeHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">ChangeHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/ClickHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">ClickHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/ContextMenuHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">ContextMenuHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DoubleClickHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">DoubleClickHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragEndHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">DragEndHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragEnterClickHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">DragEnterClickHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragEnterHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">DragEnterHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">DragHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragLeaveHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">DragLeaveHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragOverHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">DragOverHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DragStartHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">DragStartHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/DropHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">DropHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/EndedHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">EndedHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/ErrorHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">ErrorHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/FocusHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">FocusHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/GestureChangeHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">GestureChangeHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/GestureEndHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">GestureEndHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/GestureStartHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">GestureStartHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/KeyDownHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">KeyDownHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/KeyPressHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">KeyPressHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/KeyUpHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">KeyUpHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/LoadHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">LoadHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/LoseCaptureHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">LoseCaptureHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseDownHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">MouseDownHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseMoveHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">MouseMoveHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseOutHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">MouseOutHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseOverHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">MouseOverHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseUpHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">MouseUpHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/MouseWheelHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">MouseWheelHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/ProgressHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">ProgressHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/ScrollHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">ScrollHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchCancelHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">TouchCancelHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchEndHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">TouchEndHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchMoveHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">TouchMoveHandler</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/TouchStartHandler.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">TouchStartHandler</span></a></li> </ul> </li> <li type="circle">com.google.gwt.event.shared.<a href="../../../../../../com/google/gwt/event/shared/HasHandlers.html" title="interface in com.google.gwt.event.shared"><span class="strong">HasHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasBlurHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasBlurHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllFocusHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllFocusHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasFocusHandlers.html" title="interface in com.google.gwt.event.dom.client">HasFocusHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasCanPlayThroughHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasCanPlayThroughHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllMediaHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllMediaHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasEndedHandlers.html" title="interface in com.google.gwt.event.dom.client">HasEndedHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasProgressHandlers.html" title="interface in com.google.gwt.event.dom.client">HasProgressHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasChangeHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasChangeHandlers</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasClickHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasClickHandlers</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasContextMenuHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasContextMenuHandlers</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDoubleClickHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasDoubleClickHandlers</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEndHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasDragEndHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllDragAndDropHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllDragAndDropHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEnterHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragEnterHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragLeaveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragLeaveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragOverHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragOverHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragStartHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragStartHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDropHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDropHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEnterHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasDragEnterHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllDragAndDropHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllDragAndDropHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEndHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragEndHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragLeaveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragLeaveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragOverHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragOverHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragStartHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragStartHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDropHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDropHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasDragHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllDragAndDropHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllDragAndDropHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEndHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragEndHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEnterHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragEnterHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragLeaveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragLeaveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragOverHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragOverHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragStartHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragStartHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDropHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDropHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragLeaveHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasDragLeaveHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllDragAndDropHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllDragAndDropHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEndHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragEndHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEnterHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragEnterHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragOverHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragOverHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragStartHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragStartHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDropHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDropHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragOverHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasDragOverHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllDragAndDropHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllDragAndDropHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEndHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragEndHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEnterHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragEnterHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragLeaveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragLeaveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragStartHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragStartHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDropHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDropHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragStartHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasDragStartHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllDragAndDropHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllDragAndDropHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEndHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragEndHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEnterHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragEnterHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragLeaveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragLeaveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragOverHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragOverHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDropHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDropHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDropHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasDropHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllDragAndDropHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllDragAndDropHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEndHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragEndHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragEnterHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragEnterHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragLeaveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragLeaveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragOverHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragOverHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasDragStartHandlers.html" title="interface in com.google.gwt.event.dom.client">HasDragStartHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasEndedHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasEndedHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllMediaHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllMediaHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasCanPlayThroughHandlers.html" title="interface in com.google.gwt.event.dom.client">HasCanPlayThroughHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasProgressHandlers.html" title="interface in com.google.gwt.event.dom.client">HasProgressHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasErrorHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasErrorHandlers</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasFocusHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasFocusHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllFocusHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllFocusHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasBlurHandlers.html" title="interface in com.google.gwt.event.dom.client">HasBlurHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasGestureChangeHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasGestureChangeHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllGestureHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllGestureHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasGestureEndHandlers.html" title="interface in com.google.gwt.event.dom.client">HasGestureEndHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasGestureStartHandlers.html" title="interface in com.google.gwt.event.dom.client">HasGestureStartHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasGestureEndHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasGestureEndHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllGestureHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllGestureHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasGestureChangeHandlers.html" title="interface in com.google.gwt.event.dom.client">HasGestureChangeHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasGestureStartHandlers.html" title="interface in com.google.gwt.event.dom.client">HasGestureStartHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasGestureStartHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasGestureStartHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllGestureHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllGestureHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasGestureChangeHandlers.html" title="interface in com.google.gwt.event.dom.client">HasGestureChangeHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasGestureEndHandlers.html" title="interface in com.google.gwt.event.dom.client">HasGestureEndHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasKeyDownHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasKeyDownHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllKeyHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllKeyHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasKeyPressHandlers.html" title="interface in com.google.gwt.event.dom.client">HasKeyPressHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasKeyUpHandlers.html" title="interface in com.google.gwt.event.dom.client">HasKeyUpHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasKeyPressHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasKeyPressHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllKeyHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllKeyHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasKeyDownHandlers.html" title="interface in com.google.gwt.event.dom.client">HasKeyDownHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasKeyUpHandlers.html" title="interface in com.google.gwt.event.dom.client">HasKeyUpHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasKeyUpHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasKeyUpHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllKeyHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllKeyHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasKeyDownHandlers.html" title="interface in com.google.gwt.event.dom.client">HasKeyDownHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasKeyPressHandlers.html" title="interface in com.google.gwt.event.dom.client">HasKeyPressHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasLoadHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasLoadHandlers</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasLoseCaptureHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasLoseCaptureHandlers</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseDownHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasMouseDownHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllMouseHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllMouseHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseMoveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseMoveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseOutHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseOutHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseOverHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseOverHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseUpHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseUpHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseWheelHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseWheelHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseMoveHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasMouseMoveHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllMouseHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllMouseHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseDownHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseDownHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseOutHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseOutHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseOverHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseOverHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseUpHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseUpHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseWheelHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseWheelHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseOutHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasMouseOutHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllMouseHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllMouseHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseDownHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseDownHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseMoveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseMoveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseOverHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseOverHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseUpHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseUpHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseWheelHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseWheelHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseOverHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasMouseOverHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllMouseHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllMouseHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseDownHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseDownHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseMoveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseMoveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseOutHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseOutHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseUpHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseUpHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseWheelHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseWheelHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseUpHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasMouseUpHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllMouseHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllMouseHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseDownHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseDownHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseMoveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseMoveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseOutHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseOutHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseOverHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseOverHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseWheelHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseWheelHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseWheelHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasMouseWheelHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllMouseHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllMouseHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseDownHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseDownHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseMoveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseMoveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseOutHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseOutHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseOverHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseOverHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasMouseUpHandlers.html" title="interface in com.google.gwt.event.dom.client">HasMouseUpHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasProgressHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasProgressHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllMediaHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllMediaHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasCanPlayThroughHandlers.html" title="interface in com.google.gwt.event.dom.client">HasCanPlayThroughHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasEndedHandlers.html" title="interface in com.google.gwt.event.dom.client">HasEndedHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasScrollHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasScrollHandlers</span></a></li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchCancelHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasTouchCancelHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllTouchHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllTouchHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchEndHandlers.html" title="interface in com.google.gwt.event.dom.client">HasTouchEndHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchMoveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasTouchMoveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchStartHandlers.html" title="interface in com.google.gwt.event.dom.client">HasTouchStartHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchEndHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasTouchEndHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllTouchHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllTouchHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchCancelHandlers.html" title="interface in com.google.gwt.event.dom.client">HasTouchCancelHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchMoveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasTouchMoveHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchStartHandlers.html" title="interface in com.google.gwt.event.dom.client">HasTouchStartHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchMoveHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasTouchMoveHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllTouchHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllTouchHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchCancelHandlers.html" title="interface in com.google.gwt.event.dom.client">HasTouchCancelHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchEndHandlers.html" title="interface in com.google.gwt.event.dom.client">HasTouchEndHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchStartHandlers.html" title="interface in com.google.gwt.event.dom.client">HasTouchStartHandlers</a>)</li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchStartHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasTouchStartHandlers</span></a> <ul> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasAllTouchHandlers.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasAllTouchHandlers</span></a> (also extends com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchCancelHandlers.html" title="interface in com.google.gwt.event.dom.client">HasTouchCancelHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchEndHandlers.html" title="interface in com.google.gwt.event.dom.client">HasTouchEndHandlers</a>, com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasTouchMoveHandlers.html" title="interface in com.google.gwt.event.dom.client">HasTouchMoveHandlers</a>)</li> </ul> </li> </ul> </li> <li type="circle">com.google.gwt.event.dom.client.<a href="../../../../../../com/google/gwt/event/dom/client/HasNativeEvent.html" title="interface in com.google.gwt.event.dom.client"><span class="strong">HasNativeEvent</span></a></li> </ul> </div> <!-- ======= START OF BOTTOM NAVBAR ====== --> <div class="bottomNav"><a name="navbar_bottom"> <!-- --> </a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow"> <!-- --> </a> <ul class="navList" title="Navigation"> <li><a href="../../../../../../overview-summary.html">Overview</a></li> <li><a href="package-summary.html">Package</a></li> <li>Class</li> <li>Use</li> <li class="navBarCell1Rev">Tree</li> <li><a href="../../../../../../deprecated-list.html">Deprecated</a></li> <li><a href="../../../../../../index-all.html">Index</a></li> <li><a href="../../../../../../help-doc.html">Help</a></li> </ul> <div class="aboutLanguage"><em>GWT 2.5.0</em></div> </div> <div class="subNav"> <ul class="navList"> <li><a href="../../../../../../com/google/gwt/editor/ui/client/adapters/package-tree.html">Prev</a></li> <li><a href="../../../../../../com/google/gwt/event/logical/shared/package-tree.html">Next</a></li> </ul> <ul class="navList"> <li><a href="../../../../../../index.html?com/google/gwt/event/dom/client/package-tree.html" target="_top">Frames</a></li> <li><a href="package-tree.html" target="_top">No Frames</a></li> </ul> <ul class="navList" id="allclasses_navbar_bottom"> <li><a href="../../../../../../allclasses-noframe.html">All Classes</a></li> </ul> <div> <script type="text/javascript"><!-- allClassesLink = document.getElementById("allclasses_navbar_bottom"); if(window==top) { allClassesLink.style.display = "block"; } else { allClassesLink.style.display = "none"; } //--> </script> </div> <a name="skip-navbar_bottom"> <!-- --> </a></div> <!-- ======== END OF BOTTOM NAVBAR ======= --> </body> </html>
160.630695
1,436
0.704343
64d5bd047375b534480a4674ea75b4845968046a
27,923
java
Java
byte-buddy-dep/src/test/java/net/bytebuddy/description/type/TypeDescriptionGenericVisitorAssignerTest.java
zouzhberk/byte-buddy
78ecadab5c7e54863721673794b335f6340ee8db
[ "Apache-2.0" ]
1
2021-07-26T14:11:44.000Z
2021-07-26T14:11:44.000Z
byte-buddy-dep/src/test/java/net/bytebuddy/description/type/TypeDescriptionGenericVisitorAssignerTest.java
zouzhberk/byte-buddy
78ecadab5c7e54863721673794b335f6340ee8db
[ "Apache-2.0" ]
null
null
null
byte-buddy-dep/src/test/java/net/bytebuddy/description/type/TypeDescriptionGenericVisitorAssignerTest.java
zouzhberk/byte-buddy
78ecadab5c7e54863721673794b335f6340ee8db
[ "Apache-2.0" ]
null
null
null
package net.bytebuddy.description.type; import net.bytebuddy.description.field.FieldList; import net.bytebuddy.test.utility.ObjectPropertyAssertion; import org.junit.Before; import org.junit.Test; import java.io.Serializable; import java.util.AbstractList; import java.util.ArrayList; import java.util.Collection; import java.util.List; import java.util.concurrent.Callable; import static net.bytebuddy.matcher.ElementMatchers.named; import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.core.Is.is; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.when; public class TypeDescriptionGenericVisitorAssignerTest { private TypeDescription.Generic collectionWildcard, collectionRaw; private TypeDescription.Generic collectionTypeVariableT, collectionTypeVariableS, collectionTypeVariableU; private TypeDescription.Generic collectionUpperBoundTypeVariableT, collectionUpperBoundTypeVariableS, collectionUpperBoundTypeVariableU; private TypeDescription.Generic collectionLowerBoundTypeVariableT, collectionLowerBoundTypeVariableS, collectionLowerBoundTypeVariableU; private TypeDescription.Generic listRaw, listWildcard; private TypeDescription.Generic abstractListRaw, arrayListRaw, arrayListWildcard; private TypeDescription.Generic callableWildcard; private TypeDescription.Generic arrayListTypeVariableT, arrayListTypeVariableS; private TypeDescription.Generic collectionRawArray, listRawArray, listWildcardArray, arrayListRawArray; private TypeDescription.Generic stringArray, objectArray, objectNestedArray; private TypeDescription.Generic unboundWildcard; private TypeDescription.Generic typeVariableT, typeVariableS, typeVariableU, typeVariableV; private TypeDescription.Generic arrayTypeVariableT, arrayTypeVariableS, arrayTypeVariableU; private TypeDescription.Generic arrayNestedTypeVariableT; @Before public void setUp() throws Exception { FieldList<?> fields = new TypeDescription.ForLoadedType(GenericTypes.class).getDeclaredFields(); collectionRaw = fields.filter(named("collectionRaw")).getOnly().getType(); collectionWildcard = fields.filter(named("collectionWildcard")).getOnly().getType(); collectionTypeVariableT = fields.filter(named("collectionTypeVariableT")).getOnly().getType(); collectionTypeVariableS = fields.filter(named("collectionTypeVariableS")).getOnly().getType(); collectionTypeVariableU = fields.filter(named("collectionTypeVariableU")).getOnly().getType(); collectionUpperBoundTypeVariableT = fields.filter(named("collectionUpperBoundTypeVariableT")).getOnly().getType(); collectionUpperBoundTypeVariableS = fields.filter(named("collectionUpperBoundTypeVariableS")).getOnly().getType(); collectionUpperBoundTypeVariableU = fields.filter(named("collectionUpperBoundTypeVariableU")).getOnly().getType(); collectionLowerBoundTypeVariableT = fields.filter(named("collectionLowerBoundTypeVariableT")).getOnly().getType(); collectionLowerBoundTypeVariableS = fields.filter(named("collectionLowerBoundTypeVariableS")).getOnly().getType(); collectionLowerBoundTypeVariableU = fields.filter(named("collectionLowerBoundTypeVariableU")).getOnly().getType(); listRaw = fields.filter(named("listRaw")).getOnly().getType(); listWildcard = fields.filter(named("listWildcard")).getOnly().getType(); arrayListTypeVariableT = fields.filter(named("arrayListTypeVariableT")).getOnly().getType(); arrayListTypeVariableS = fields.filter(named("arrayListTypeVariableS")).getOnly().getType(); TypeDescription.Generic arrayListTypeVariableU = fields.filter(named("arrayListTypeVariableU")).getOnly().getType(); TypeDescription.Generic arrayListTypeVariableV = fields.filter(named("arrayListTypeVariableV")).getOnly().getType(); abstractListRaw = fields.filter(named("abstractListRaw")).getOnly().getType(); callableWildcard = fields.filter(named("callableWildcard")).getOnly().getType(); arrayListRaw = fields.filter(named("arrayListRaw")).getOnly().getType(); arrayListWildcard = fields.filter(named("arrayListWildcard")).getOnly().getType(); collectionRawArray = fields.filter(named("collectionRawArray")).getOnly().getType(); listRawArray = fields.filter(named("listRawArray")).getOnly().getType(); listWildcardArray = fields.filter(named("listWildcardArray")).getOnly().getType(); arrayListRawArray = fields.filter(named("arrayListRawArray")).getOnly().getType(); stringArray = new TypeDescription.Generic.OfNonGenericType.ForLoadedType(String[].class); objectArray = new TypeDescription.Generic.OfNonGenericType.ForLoadedType(Object[].class); objectNestedArray = new TypeDescription.Generic.OfNonGenericType.ForLoadedType(Object[][].class); unboundWildcard = listWildcard.getTypeArguments().getOnly(); typeVariableT = arrayListTypeVariableT.getTypeArguments().getOnly(); typeVariableS = arrayListTypeVariableS.getTypeArguments().getOnly(); typeVariableU = arrayListTypeVariableU.getTypeArguments().getOnly(); typeVariableV = arrayListTypeVariableV.getTypeArguments().getOnly(); arrayTypeVariableT = fields.filter(named("arrayTypeVariableT")).getOnly().getType(); arrayTypeVariableS = fields.filter(named("arrayTypeVariableS")).getOnly().getType(); arrayTypeVariableU = fields.filter(named("arrayTypeVariableU")).getOnly().getType(); arrayNestedTypeVariableT = fields.filter(named("arrayNestedTypeVariableT")).getOnly().getType(); } @Test(expected = IllegalArgumentException.class) public void testAssignFromWildcardThrowsException() throws Exception { unboundWildcard.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE); } @Test public void testAssignNonGenericTypeFromAssignableNonGenericType() throws Exception { assertThat(TypeDescription.Generic.OBJECT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(TypeDescription.STRING.asGenericType()), is(true)); } @Test public void testAssignNonGenericTypeFromNonAssignableNonGenericType() throws Exception { assertThat(TypeDescription.STRING.asGenericType().accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(TypeDescription.Generic.OBJECT), is(false)); } @Test public void testAssignObjectTypeFromAssignableGenericType() throws Exception { assertThat(TypeDescription.Generic.OBJECT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcard), is(true)); } @Test public void testAssignNonGenericTypeFromNonAssignableGenericType() throws Exception { assertThat(TypeDescription.STRING.asGenericType().accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcard), is(false)); } @Test public void testAssignNonGenericSuperInterfaceTypeFromAssignableGenericInterfaceType() throws Exception { assertThat(collectionRaw.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcard), is(true)); } @Test public void testAssignNonGenericSuperInterfaceTypeFromAssignableGenericType() throws Exception { assertThat(collectionRaw.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayListWildcard), is(true)); } @Test public void testAssignRawInterfaceTypeFromEqualGenericInterfaceType() throws Exception { assertThat(listRaw.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcard), is(true)); } @Test public void testAssignRawTypeFromEqualGenericType() throws Exception { assertThat(arrayListRaw.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayListWildcard), is(true)); } @Test public void testAssignNonGenericSuperTypeFromAssignableGenericType() throws Exception { assertThat(abstractListRaw.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayListWildcard), is(true)); } @Test(expected = IllegalArgumentException.class) public void testAssignNonGenericTypeFromWildcardThrowsException() throws Exception { TypeDescription.Generic.OBJECT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(unboundWildcard); } @Test public void testAssignNonGenericTypeFromAssignableTypeVariable() throws Exception { assertThat(TypeDescription.Generic.OBJECT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(typeVariableT), is(true)); } @Test public void testAssignNonGenericTypeFromNonAssignableTypeVariable() throws Exception { assertThat(TypeDescription.STRING.asGenericType().accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(typeVariableT), is(false)); } @Test public void testAssignNonGenericSuperArrayTypeFromAssignableGenericArrayType() throws Exception { assertThat(collectionRawArray.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcardArray), is(true)); } @Test public void testAssignRawArrayTypeFromEqualGenericArrayType() throws Exception { assertThat(listRawArray.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcardArray), is(true)); } @Test public void testAssignNonGenericArrayFromNonAssignableGenericArrayType() throws Exception { assertThat(stringArray.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcardArray), is(false)); } @Test public void testAssignNonGenericArrayFromAssignableGenericArrayType() throws Exception { assertThat(objectArray.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcardArray), is(true)); } @Test public void testAssignNonGenericArrayFromGenericArrayTypeOfIncompatibleArity() throws Exception { assertThat(objectNestedArray.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcardArray), is(false)); } @Test public void testAssignObjectTypeFromGenericArrayType() throws Exception { assertThat(TypeDescription.Generic.OBJECT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcardArray), is(true)); } @Test public void testAssignCloneableTypeFromGenericArrayType() throws Exception { assertThat(new TypeDescription.Generic.OfNonGenericType.ForLoadedType(Cloneable.class).accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcardArray), is(true)); } @Test public void testAssignSerializableTypeFromGenericArrayType() throws Exception { assertThat(new TypeDescription.Generic.OfNonGenericType.ForLoadedType(Serializable.class).accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcardArray), is(true)); } @Test public void testAssignTypeVariableFromNonGenericType() throws Exception { assertThat(typeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(TypeDescription.Generic.OBJECT), is(false)); } @Test(expected = IllegalArgumentException.class) public void testAssignTypeVariableFromWildcardTypeThrowsException() throws Exception { typeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(unboundWildcard); } @Test public void testAssignTypeVariableFromGenericArrayType() throws Exception { assertThat(typeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcardArray), is(false)); } @Test public void testAssignTypeVariableFromParameterizedType() throws Exception { assertThat(typeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(listWildcard), is(false)); } @Test public void testAssignTypeVariableFromEqualTypeVariable() throws Exception { assertThat(typeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(typeVariableT), is(true)); } @Test public void testAssignTypeVariableFromNonAssignableWildcard() throws Exception { assertThat(typeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(typeVariableS), is(false)); } @Test public void testAssignTypeVariableFromAssignableWildcard() throws Exception { assertThat(typeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(typeVariableU), is(true)); } @Test public void testAssignGenericArrayFromAssignableGenericArray() throws Exception { assertThat(arrayTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayTypeVariableU), is(true)); } @Test public void testAssignGenericNestedArrayFromNonAssignableGenericArray() throws Exception { assertThat(arrayTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayNestedTypeVariableT), is(false)); } @Test public void testAssignGenericNestedArrayFromAssignableObjectArray() throws Exception { assertThat(new TypeDescription.Generic.OfNonGenericType.ForLoadedType(Object[][].class).accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayNestedTypeVariableT), is(true)); } @Test public void testAssignGenericArrayFromNonAssignableGenericArray() throws Exception { assertThat(arrayTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayTypeVariableS), is(false)); } @Test public void testAssignGenericArrayFromNonAssignableNonGenericNonArrayType() throws Exception { assertThat(arrayTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(TypeDescription.Generic.OBJECT), is(false)); } @Test public void testAssignGenericArrayFromNonAssignableNonGenericArrayType() throws Exception { assertThat(arrayTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(objectArray), is(false)); } @Test public void testAssignGenericArrayFromAssignableNonGenericArrayType() throws Exception { assertThat(listWildcardArray.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayListRawArray), is(true)); } @Test public void testAssignGenericArrayFromNonAssignableTypeVariable() throws Exception { assertThat(arrayTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(typeVariableT), is(false)); } @Test public void testAssignGenericArrayFromNonAssignableParameterizedType() throws Exception { assertThat(arrayTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayListWildcard), is(false)); } @Test(expected = IllegalArgumentException.class) public void testAssignGenericArrayFromWildcardThrowsException() throws Exception { arrayTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(unboundWildcard); } @Test public void testAssignParameterizedWildcardTypeFromEqualType() throws Exception { assertThat(collectionWildcard.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionWildcard), is(true)); } @Test public void testAssignParameterizedWildcardTypeFromEqualRawType() throws Exception { assertThat(collectionWildcard.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionRaw), is(true)); } @Test public void testAssignParameterizedWildcardTypeFromAssignableParameterizedWildcardType() throws Exception { assertThat(collectionWildcard.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayListWildcard), is(true)); } @Test public void testAssignParameterizedWildcardTypeFromAssignableParameterizedNonWildcardTypeType() throws Exception { assertThat(collectionWildcard.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayListTypeVariableT), is(true)); } @Test public void testAssignParameterizedWildcardTypeFromAssignableTypeVariableType() throws Exception { assertThat(collectionWildcard.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(typeVariableV), is(true)); } @Test public void testAssignParameterizedWildcardTypeFromNonAssignableRawType() throws Exception { assertThat(collectionWildcard.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(TypeDescription.STRING.asGenericType()), is(false)); } @Test public void testAssignParameterizedWildcardTypeFromNonAssignableParameterizedType() throws Exception { assertThat(collectionWildcard.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(callableWildcard), is(false)); } @Test public void testAssignParameterizedWildcardTypeFromNonAssignableGenericArrayType() throws Exception { assertThat(collectionWildcard.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayTypeVariableT), is(false)); } @Test public void testAssignParameterizedWildcardTypeFromNonAssignableTypeVariableType() throws Exception { assertThat(collectionWildcard.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(typeVariableT), is(false)); } @Test public void testAssignParameterizedTypeVariableTypeFromEqualParameterizedTypeVariableTypeType() throws Exception { assertThat(collectionTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionTypeVariableT), is(true)); } @Test public void testAssignParameterizedTypeVariableTypeFromAssignableParameterizedTypeVariableTypeType() throws Exception { assertThat(collectionTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayListTypeVariableT), is(true)); } @Test public void testAssignParameterizedTypeVariableTypeFromNonAssignableParameterizedTypeVariableTypeType() throws Exception { assertThat(collectionTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(arrayListTypeVariableS), is(false)); } @Test public void testAssignUpperBoundFromAssignableBound() throws Exception { assertThat(collectionUpperBoundTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionTypeVariableT), is(true)); } @Test public void testAssignUpperBoundFromAssignableBoundSuperType() throws Exception { assertThat(collectionUpperBoundTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionTypeVariableU), is(true)); } @Test public void testAssignUpperBoundFromAssignableUpperBoundSuperType() throws Exception { assertThat(collectionUpperBoundTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionUpperBoundTypeVariableU), is(true)); } @Test public void testAssignUpperBoundFromAssignableUpperBoundEqualType() throws Exception { assertThat(collectionUpperBoundTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionTypeVariableU), is(true)); } @Test public void testAssignUpperBoundFromNonAssignableBoundType() throws Exception { assertThat(collectionUpperBoundTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionTypeVariableS), is(false)); } @Test public void testAssignUpperBoundFromNonAssignableUpperBoundType() throws Exception { assertThat(collectionUpperBoundTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionUpperBoundTypeVariableS), is(false)); } @Test public void testAssignUpperBoundFromLowerpperBoundType() throws Exception { assertThat(collectionUpperBoundTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionLowerBoundTypeVariableT), is(false)); } @Test public void testAssignLowerBoundFromAssignableBound() throws Exception { assertThat(collectionLowerBoundTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionTypeVariableT), is(true)); } @Test public void testAssignLowerBoundFromAssignableBoundSuperType() throws Exception { assertThat(collectionLowerBoundTypeVariableU.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionTypeVariableT), is(true)); } @Test public void testAssignLowerBoundFromAssignableUpperBoundSuperType() throws Exception { assertThat(collectionLowerBoundTypeVariableU.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionLowerBoundTypeVariableT), is(true)); } @Test public void testAssigLowerBoundFromAssignableUpperBoundEqualType() throws Exception { assertThat(collectionLowerBoundTypeVariableU.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionTypeVariableT), is(true)); } @Test public void testAssignLowerBoundFromNonAssignableBoundType() throws Exception { assertThat(collectionLowerBoundTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionTypeVariableS), is(false)); } @Test public void testAssignLowerBoundFromNonAssignableUpperBoundType() throws Exception { assertThat(collectionLowerBoundTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionLowerBoundTypeVariableS), is(false)); } @Test public void testAssignLowerBoundFromLowerpperBoundType() throws Exception { assertThat(collectionLowerBoundTypeVariableT.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionUpperBoundTypeVariableT), is(false)); } @Test public void testAssignLowerBoundFromAssignableBoundSubType() throws Exception { assertThat(collectionLowerBoundTypeVariableU.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(collectionTypeVariableT), is(true)); } @Test(expected = IllegalArgumentException.class) public void testAssignParameterizedTypeFromWildcardTypeThrowsException() throws Exception { collectionWildcard.accept(TypeDescription.Generic.Visitor.Assigner.INSTANCE) .isAssignableFrom(unboundWildcard); } @Test(expected = IllegalArgumentException.class) public void testAssignIncompatibleParameterizedTypesThrowsException() throws Exception { TypeDescription.Generic source = mock(TypeDescription.Generic.class), target = mock(TypeDescription.Generic.class); TypeDescription erasure = mock(TypeDescription.class); when(source.asErasure()).thenReturn(erasure); when(target.asErasure()).thenReturn(erasure); when(source.getTypeArguments()).thenReturn(new TypeList.Generic.Empty()); when(target.getTypeArguments()).thenReturn(new TypeList.Generic.Explicit(mock(TypeDescription.Generic.class))); new TypeDescription.Generic.Visitor.Assigner.Dispatcher.ForParameterizedType(target).onParameterizedType(source); } @Test public void testObjectProperties() throws Exception { ObjectPropertyAssertion.of(TypeDescription.Generic.Visitor.Assigner.class).apply(); ObjectPropertyAssertion.of(TypeDescription.Generic.Visitor.Assigner.Dispatcher.ForGenericArray.class).apply(); ObjectPropertyAssertion.of(TypeDescription.Generic.Visitor.Assigner.Dispatcher.ForNonGenericType.class).apply(); ObjectPropertyAssertion.of(TypeDescription.Generic.Visitor.Assigner.Dispatcher.ForTypeVariable.class).apply(); ObjectPropertyAssertion.of(TypeDescription.Generic.Visitor.Assigner.Dispatcher.ForParameterizedType.class).apply(); ObjectPropertyAssertion.of(TypeDescription.Generic.Visitor.Assigner.Dispatcher.ForParameterizedType.ParameterAssigner.class).apply(); ObjectPropertyAssertion.of(TypeDescription.Generic.Visitor.Assigner.Dispatcher.ForParameterizedType.ParameterAssigner.InvariantBinding.class).apply(); ObjectPropertyAssertion.of(TypeDescription.Generic.Visitor.Assigner.Dispatcher.ForParameterizedType.ParameterAssigner.CovariantBinding.class).apply(); ObjectPropertyAssertion.of(TypeDescription.Generic.Visitor.Assigner.Dispatcher.ForParameterizedType.ParameterAssigner.ContravariantBinding.class).apply(); } @SuppressWarnings({"unused", "unchecked"}) private static class GenericTypes<T, S, U extends T, V extends List<?>> { private Collection collectionRaw; private Collection<?> collectionWildcard; private Collection<T> collectionTypeVariableT; private Collection<S> collectionTypeVariableS; private Collection<U> collectionTypeVariableU; private Collection<? extends T> collectionUpperBoundTypeVariableT; private Collection<? extends S> collectionUpperBoundTypeVariableS; private Collection<? extends U> collectionUpperBoundTypeVariableU; private Collection<? super T> collectionLowerBoundTypeVariableT; private Collection<? super S> collectionLowerBoundTypeVariableS; private Collection<? super U> collectionLowerBoundTypeVariableU; private Collection[] collectionRawArray; private List listRaw; private List<?> listWildcard; private List[] listRawArray; private List<?>[] listWildcardArray; private AbstractList abstractListRaw; private ArrayList arrayListRaw; private ArrayList<?> arrayListWildcard; private ArrayList[] arrayListRawArray; private ArrayList<T> arrayListTypeVariableT; private ArrayList<S> arrayListTypeVariableS; private ArrayList<U> arrayListTypeVariableU; private ArrayList<V> arrayListTypeVariableV; private Callable<?> callableWildcard; private T[] arrayTypeVariableT; private T[][] arrayNestedTypeVariableT; private S[] arrayTypeVariableS; private U[] arrayTypeVariableU; } }
48.646341
162
0.75744
03e9e7a7cfb392407ea8c9e5b1f57e8718d3b8e2
3,193
dart
Dart
lib/src/extend/extension.dart
yringler/dart-sass
3b36b5e638f303e10c3666683474da4f80309443
[ "MIT" ]
4
2021-04-16T10:38:00.000Z
2021-04-16T19:30:01.000Z
lib/src/extend/extension.dart
yringler/dart-sass
3b36b5e638f303e10c3666683474da4f80309443
[ "MIT" ]
null
null
null
lib/src/extend/extension.dart
yringler/dart-sass
3b36b5e638f303e10c3666683474da4f80309443
[ "MIT" ]
null
null
null
// Copyright 2016 Google Inc. Use of this source code is governed by an // MIT-style license that can be found in the LICENSE file or at // https://opensource.org/licenses/MIT. import 'package:source_span/source_span.dart'; import '../ast/css.dart'; import '../ast/selector.dart'; import '../exception.dart'; import '../utils.dart'; /// The state of an extension for a given extender. /// /// The target of the extension is represented externally, in the map that /// contains this extender. class Extension { /// The selector in which the `@extend` appeared. final ComplexSelector extender; /// The selector that's being extended. /// /// `null` for one-off extensions. final SimpleSelector target; /// The minimum specificity required for any selector generated from this /// extender. final int specificity; /// Whether this extension is optional. final bool isOptional; /// Whether this is a one-off extender representing a selector that was /// originally in the document, rather than one defined with `@extend`. final bool isOriginal; /// The media query context to which this extend is restricted, or `null` if /// it can apply within any context. final List<CssMediaQuery> mediaContext; /// The span in which [extender] was defined. /// /// `null` for one-off extensions. final FileSpan extenderSpan; /// The span for an `@extend` rule that defined this extension. /// /// If any extend rule for this is extension is mandatory, this is guaranteed /// to be a span for a mandatory rule. final FileSpan span; /// Creates a new extension. /// /// If [specificity] isn't passed, it defaults to `extender.maxSpecificity`. Extension(ComplexSelector extender, this.target, this.extenderSpan, this.span, this.mediaContext, {int specificity, bool optional = false}) : extender = extender, specificity = specificity ?? extender.maxSpecificity, isOptional = optional, isOriginal = false; /// Creates a one-off extension that's not intended to be modified over time. /// /// If [specificity] isn't passed, it defaults to `extender.maxSpecificity`. Extension.oneOff(ComplexSelector extender, {int specificity, this.isOriginal = false}) : extender = extender, target = null, extenderSpan = null, specificity = specificity ?? extender.maxSpecificity, isOptional = true, mediaContext = null, span = null; /// Asserts that the [mediaContext] for a selector is compatible with the /// query context for this extender. void assertCompatibleMediaContext(List<CssMediaQuery> mediaContext) { if (this.mediaContext == null) return; if (mediaContext != null && listEquals(this.mediaContext, mediaContext)) { return; } throw SassException( "You may not @extend selectors across media queries.", span); } Extension withExtender(ComplexSelector newExtender) => Extension(newExtender, target, extenderSpan, span, mediaContext, specificity: specificity, optional: isOptional); String toString() => "$extender {@extend $target${isOptional ? ' !optional' : ''}}"; }
33.968085
80
0.691826
a3a7d40c8fb2817daa7f78effad69088fad6f64c
604
asm
Assembly
oeis/224/A224336.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
11
2021-08-22T19:44:55.000Z
2022-03-20T16:47:57.000Z
oeis/224/A224336.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
9
2021-08-29T13:15:54.000Z
2022-03-09T19:52:31.000Z
oeis/224/A224336.asm
neoneye/loda-programs
84790877f8e6c2e821b183d2e334d612045d29c0
[ "Apache-2.0" ]
3
2021-08-22T20:56:47.000Z
2021-09-29T06:26:12.000Z
; A224336: Number of idempotent 5X5 0..n matrices of rank 4. ; 155,805,2555,6245,12955,24005,40955,65605,99995,146405,207355,285605,384155,506245,655355,835205,1049755,1303205,1599995,1944805,2342555,2798405,3317755,3906245,4569755,5314405,6146555,7072805,8099995,9235205,10485755,11859205,13363355,15006245,16796155,18741605,20851355,23134405,25599995,28257605,31116955,34188005,37480955,41006245,44774555,48796805,53084155,57648005,62499995,67652005,73116155,78904805,85030555,91506245,98344955,105560005,113164955,121173605,129599995,138458405,147763355 add $0,2 pow $0,4 sub $0,1 mul $0,10 add $0,5
67.111111
495
0.834437
8f0199e834eafc5dac5345bba2531760d2db8b52
73,725
java
Java
doclava/src/com/google/doclava/ClassInfo.java
Keneral/ae1
e5bbf05e3a01b449f33cca14c5ce8048df45624b
[ "Unlicense" ]
null
null
null
doclava/src/com/google/doclava/ClassInfo.java
Keneral/ae1
e5bbf05e3a01b449f33cca14c5ce8048df45624b
[ "Unlicense" ]
null
null
null
doclava/src/com/google/doclava/ClassInfo.java
Keneral/ae1
e5bbf05e3a01b449f33cca14c5ce8048df45624b
[ "Unlicense" ]
null
null
null
/* * Copyright (C) 2010 Google Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.google.doclava; import com.google.clearsilver.jsilver.data.Data; import com.sun.javadoc.ClassDoc; import java.util.ArrayDeque; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; import java.util.Comparator; import java.util.HashMap; import java.util.HashSet; import java.util.Iterator; import java.util.List; import java.util.Map; import java.util.Queue; import java.util.Set; import java.util.TreeMap; public class ClassInfo extends DocInfo implements ContainerInfo, Comparable, Scoped, Resolvable { /** * Contains a ClassInfo and a TypeInfo. * <p> * This is used to match a ClassInfo, which doesn't keep track of its type parameters * and a type which does. */ private class ClassTypePair { private final ClassInfo mClassInfo; private final TypeInfo mTypeInfo; public ClassTypePair(ClassInfo cl, TypeInfo t) { mClassInfo = cl; mTypeInfo = t; } public ClassInfo classInfo() { return mClassInfo; } public TypeInfo typeInfo() { return mTypeInfo; } public Map<String, TypeInfo> getTypeArgumentMapping() { return TypeInfo.getTypeArgumentMapping(classInfo(), typeInfo()); } } public static final Comparator<ClassInfo> comparator = new Comparator<ClassInfo>() { public int compare(ClassInfo a, ClassInfo b) { return a.name().compareTo(b.name()); } }; public static final Comparator<ClassInfo> qualifiedComparator = new Comparator<ClassInfo>() { public int compare(ClassInfo a, ClassInfo b) { return a.qualifiedName().compareTo(b.qualifiedName()); } }; /** * Constructs a stub representation of a class. */ public ClassInfo(String qualifiedName) { super("", SourcePositionInfo.UNKNOWN); mQualifiedName = qualifiedName; if (qualifiedName.lastIndexOf('.') != -1) { mName = qualifiedName.substring(qualifiedName.lastIndexOf('.') + 1); } else { mName = qualifiedName; } } public ClassInfo(ClassDoc cl, String rawCommentText, SourcePositionInfo position, boolean isPublic, boolean isProtected, boolean isPackagePrivate, boolean isPrivate, boolean isStatic, boolean isInterface, boolean isAbstract, boolean isOrdinaryClass, boolean isException, boolean isError, boolean isEnum, boolean isAnnotation, boolean isFinal, boolean isIncluded, String name, String qualifiedName, String qualifiedTypeName, boolean isPrimitive) { super(rawCommentText, position); initialize(rawCommentText, position, isPublic, isProtected, isPackagePrivate, isPrivate, isStatic, isInterface, isAbstract, isOrdinaryClass, isException, isError, isEnum, isAnnotation, isFinal, isIncluded, qualifiedTypeName, isPrimitive, null); mName = name; mQualifiedName = qualifiedName; mNameParts = name.split("\\."); mClass = cl; } public void initialize(String rawCommentText, SourcePositionInfo position, boolean isPublic, boolean isProtected, boolean isPackagePrivate, boolean isPrivate, boolean isStatic, boolean isInterface, boolean isAbstract, boolean isOrdinaryClass, boolean isException, boolean isError, boolean isEnum, boolean isAnnotation, boolean isFinal, boolean isIncluded, String qualifiedTypeName, boolean isPrimitive, ArrayList<AnnotationInstanceInfo> annotations) { // calls setPosition(position); setRawCommentText(rawCommentText); mIsPublic = isPublic; mIsProtected = isProtected; mIsPackagePrivate = isPackagePrivate; mIsPrivate = isPrivate; mIsStatic = isStatic; mIsInterface = isInterface; mIsAbstract = isAbstract; mIsOrdinaryClass = isOrdinaryClass; mIsException = isException; mIsError = isError; mIsEnum = isEnum; mIsAnnotation = isAnnotation; mIsFinal = isFinal; mIsIncluded = isIncluded; mQualifiedTypeName = qualifiedTypeName; mIsPrimitive = isPrimitive; mAnnotations = annotations; mShowAnnotations = AnnotationInstanceInfo.getShowAnnotationsIntersection(annotations); } public void init(TypeInfo typeInfo, ArrayList<ClassInfo> interfaces, ArrayList<TypeInfo> interfaceTypes, ArrayList<ClassInfo> innerClasses, ArrayList<MethodInfo> constructors, ArrayList<MethodInfo> methods, ArrayList<MethodInfo> annotationElements, ArrayList<FieldInfo> fields, ArrayList<FieldInfo> enumConstants, PackageInfo containingPackage, ClassInfo containingClass, ClassInfo superclass, TypeInfo superclassType, ArrayList<AnnotationInstanceInfo> annotations) { mTypeInfo = typeInfo; mRealInterfaces = new ArrayList<ClassInfo>(interfaces); mRealInterfaceTypes = interfaceTypes; mInnerClasses = innerClasses; // mAllConstructors will not contain *all* constructors. Only the constructors that pass // checkLevel. @see {@link Converter#convertMethods(ConstructorDoc[])} mAllConstructors = constructors; // mAllSelfMethods will not contain *all* self methods. Only the methods that pass // checkLevel. @see {@link Converter#convertMethods(MethodDoc[])} mAllSelfMethods = methods; mAnnotationElements = annotationElements; // mAllSelfFields will not contain *all* self fields. Only the fields that pass // checkLevel. @see {@link Converter#convetFields(FieldDoc[])} mAllSelfFields = fields; // mEnumConstants will not contain *all* enum constants. Only the enums that pass // checkLevel. @see {@link Converter#convetFields(FieldDoc[])} mEnumConstants = enumConstants; mContainingPackage = containingPackage; mContainingClass = containingClass; mRealSuperclass = superclass; mRealSuperclassType = superclassType; mAnnotations = annotations; mShowAnnotations = AnnotationInstanceInfo.getShowAnnotationsIntersection(annotations); // after providing new methods and new superclass info,clear any cached // lists of self + superclass methods, ctors, etc. mSuperclassInit = false; mConstructors = null; mMethods = null; mSelfMethods = null; mFields = null; mSelfFields = null; mSelfAttributes = null; mDeprecatedKnown = false; mSuperclassesWithTypes = null; mInterfacesWithTypes = null; mAllInterfacesWithTypes = null; Collections.sort(mEnumConstants, FieldInfo.comparator); Collections.sort(mInnerClasses, ClassInfo.comparator); } public void init2() { // calling this here forces the AttrTagInfo objects to be linked to the AttribtueInfo // objects selfAttributes(); } public void init3(ArrayList<TypeInfo> types, ArrayList<ClassInfo> realInnerClasses) { mTypeParameters = types; mRealInnerClasses = realInnerClasses; } public ArrayList<ClassInfo> getRealInnerClasses() { return mRealInnerClasses; } public ArrayList<TypeInfo> getTypeParameters() { return mTypeParameters; } /** * @return true if this class needs to be shown in api txt, based on the * hidden/removed status of the class and the show level setting in doclava. */ public boolean checkLevel() { if (mCheckLevel == null) { mCheckLevel = Doclava.checkLevel(mIsPublic, mIsProtected, mIsPackagePrivate, mIsPrivate, isHiddenOrRemoved()); } return mCheckLevel; } public int compareTo(Object that) { if (that instanceof ClassInfo) { return mQualifiedName.compareTo(((ClassInfo) that).mQualifiedName); } else { return this.hashCode() - that.hashCode(); } } @Override public ContainerInfo parent() { return this; } public boolean isPublic() { return mIsPublic; } public boolean isProtected() { return mIsProtected; } public boolean isPackagePrivate() { return mIsPackagePrivate; } public boolean isPrivate() { return mIsPrivate; } public boolean isStatic() { return mIsStatic; } public boolean isInterface() { return mIsInterface; } public boolean isAbstract() { return mIsAbstract; } public PackageInfo containingPackage() { return mContainingPackage; } public ClassInfo containingClass() { return mContainingClass; } public boolean isOrdinaryClass() { return mIsOrdinaryClass; } public boolean isException() { return mIsException; } public boolean isError() { return mIsError; } public boolean isEnum() { return mIsEnum; } public boolean isAnnotation() { return mIsAnnotation; } public boolean isFinal() { return mIsFinal; } public boolean isEffectivelyFinal() { return mIsFinal || mApiCheckConstructors.isEmpty(); } public boolean isIncluded() { return mIsIncluded; } public HashSet<String> typeVariables() { HashSet<String> result = TypeInfo.typeVariables(mTypeInfo.typeArguments()); ClassInfo cl = containingClass(); while (cl != null) { ArrayList<TypeInfo> types = cl.asTypeInfo().typeArguments(); if (types != null) { TypeInfo.typeVariables(types, result); } cl = cl.containingClass(); } return result; } /** * List of only direct interface's classes, without worrying about type param mapping. * This can't be lazy loaded, because its overloads depend on changing type parameters * passed in from the callers. */ private List<ClassTypePair> justMyInterfacesWithTypes() { return justMyInterfacesWithTypes(Collections.<String, TypeInfo>emptyMap()); } /** * List of only direct interface's classes and their parameterized types. * This can't be lazy loaded, because of the passed in typeArgumentsMap. */ private List<ClassTypePair> justMyInterfacesWithTypes(Map<String, TypeInfo> typeArgumentsMap) { if (mRealInterfaces == null || mRealInterfaceTypes == null) { return Collections.<ClassTypePair>emptyList(); } List<ClassTypePair> list = new ArrayList<ClassTypePair>(); for (int i = 0; i < mRealInterfaces.size(); i++) { ClassInfo iface = mRealInterfaces.get(i); TypeInfo type = mRealInterfaceTypes.get(i); if (iface != null && type != null) { type = type.getTypeWithArguments(typeArgumentsMap); if (iface.checkLevel()) { list.add(new ClassTypePair(iface, type)); } else { // add the interface's interfaces Map<String, TypeInfo> map = TypeInfo.getTypeArgumentMapping(iface.asTypeInfo(), type); list.addAll(iface.justMyInterfacesWithTypes(map)); } } } return list; } /** * List of only direct interface's classes, and any hidden superclass's direct interfaces * between this class and the first visible superclass and those interface class's parameterized types. */ private ArrayList<ClassTypePair> interfacesWithTypes() { if (mInterfacesWithTypes == null) { mInterfacesWithTypes = new ArrayList<ClassTypePair>(); Iterator<ClassTypePair> itr = superClassesWithTypes().iterator(); // skip the first one, which is this class itr.next(); while (itr.hasNext()) { ClassTypePair ctp = itr.next(); if (ctp.classInfo().checkLevel()) { break; } else { // fill mInterfacesWithTypes from the hidden superclass mInterfacesWithTypes.addAll( ctp.classInfo().justMyInterfacesWithTypes(ctp.getTypeArgumentMapping())); } } mInterfacesWithTypes.addAll( justMyInterfacesWithTypes()); } return mInterfacesWithTypes; } /** * List of all interface's classes reachable in this class's inheritance hierarchy * and those interface class's parameterized types. */ private ArrayList<ClassTypePair> allInterfacesWithTypes() { if (mAllInterfacesWithTypes == null) { mAllInterfacesWithTypes = new ArrayList<ClassTypePair>(); Queue<ClassTypePair> toParse = new ArrayDeque<ClassTypePair>(); Set<String> visited = new HashSet<String>(); Iterator<ClassTypePair> itr = superClassesWithTypes().iterator(); // skip the first one, which is this class itr.next(); while (itr.hasNext()) { ClassTypePair ctp = itr.next(); toParse.addAll( ctp.classInfo().justMyInterfacesWithTypes(ctp.getTypeArgumentMapping())); } toParse.addAll(justMyInterfacesWithTypes()); while (!toParse.isEmpty()) { ClassTypePair ctp = toParse.remove(); if (!visited.contains(ctp.typeInfo().fullName())) { mAllInterfacesWithTypes.add(ctp); visited.add(ctp.typeInfo().fullName()); toParse.addAll(ctp.classInfo().justMyInterfacesWithTypes(ctp.getTypeArgumentMapping())); } } } return mAllInterfacesWithTypes; } /** * A list of ClassTypePairs that contain all superclasses * and their corresponding types. The types will have type parameters * cascaded upwards so they match, if any classes along the way set them. * The list includes the current class, and is an ascending order up the * heirarchy tree. * */ private ArrayList<ClassTypePair> superClassesWithTypes() { if (mSuperclassesWithTypes == null) { mSuperclassesWithTypes = new ArrayList<ClassTypePair>(); ClassTypePair lastCtp = new ClassTypePair(this, this.asTypeInfo()); mSuperclassesWithTypes.add(lastCtp); Map<String, TypeInfo> typeArgumentsMap; ClassInfo superclass = mRealSuperclass; TypeInfo supertype = mRealSuperclassType; TypeInfo nextType; while (superclass != null && supertype != null) { typeArgumentsMap = lastCtp.getTypeArgumentMapping(); lastCtp = new ClassTypePair(superclass, supertype.getTypeWithArguments(typeArgumentsMap)); mSuperclassesWithTypes.add(lastCtp); supertype = superclass.mRealSuperclassType; superclass = superclass.mRealSuperclass; } } return mSuperclassesWithTypes; } private static void gatherHiddenInterfaces(ClassInfo cl, HashSet<ClassInfo> interfaces) { for (ClassInfo iface : cl.mRealInterfaces) { if (iface.checkLevel()) { interfaces.add(iface); } else { gatherHiddenInterfaces(iface, interfaces); } } } public ArrayList<ClassInfo> interfaces() { if (mInterfaces == null) { if (checkLevel()) { HashSet<ClassInfo> interfaces = new HashSet<ClassInfo>(); ClassInfo superclass = mRealSuperclass; while (superclass != null && !superclass.checkLevel()) { gatherHiddenInterfaces(superclass, interfaces); superclass = superclass.mRealSuperclass; } gatherHiddenInterfaces(this, interfaces); mInterfaces = new ArrayList<ClassInfo>(interfaces); } else { // put something here in case someone uses it mInterfaces = new ArrayList<ClassInfo>(mRealInterfaces); } Collections.sort(mInterfaces, ClassInfo.qualifiedComparator); } return mInterfaces; } public ArrayList<ClassInfo> realInterfaces() { return mRealInterfaces; } ArrayList<TypeInfo> realInterfaceTypes() { return mRealInterfaceTypes; } public void addInterfaceType(TypeInfo type) { if (mRealInterfaceTypes == null) { mRealInterfaceTypes = new ArrayList<TypeInfo>(); } mRealInterfaceTypes.add(type); } public String name() { return mName; } public String[] nameParts() { return mNameParts; } public String leafName() { return mNameParts[mNameParts.length - 1]; } public String qualifiedName() { return mQualifiedName; } public String qualifiedTypeName() { return mQualifiedTypeName; } public boolean isPrimitive() { return mIsPrimitive; } public ArrayList<MethodInfo> allConstructors() { return mAllConstructors; } public ArrayList<MethodInfo> constructors() { if (mConstructors == null) { if (mAllConstructors == null) { return new ArrayList<MethodInfo>(); } mConstructors = new ArrayList<MethodInfo>(); for (MethodInfo m : mAllConstructors) { if (!m.isHiddenOrRemoved()) { mConstructors.add(m); } } Collections.sort(mConstructors, MethodInfo.comparator); } return mConstructors; } public ArrayList<ClassInfo> innerClasses() { return mInnerClasses; } public TagInfo[] inlineTags() { return comment().tags(); } public TagInfo[] firstSentenceTags() { return comment().briefTags(); } public void setDeprecated(boolean deprecated) { mDeprecatedKnown = true; mIsDeprecated = deprecated; } public boolean isDeprecated() { if (!mDeprecatedKnown) { boolean commentDeprecated = comment().isDeprecated(); boolean annotationDeprecated = false; for (AnnotationInstanceInfo annotation : annotations()) { if (annotation.type().qualifiedName().equals("java.lang.Deprecated")) { annotationDeprecated = true; break; } } if (commentDeprecated != annotationDeprecated) { Errors.error(Errors.DEPRECATION_MISMATCH, position(), "Class " + qualifiedName() + ": @Deprecated annotation and @deprecated comment do not match"); } mIsDeprecated = commentDeprecated | annotationDeprecated; mDeprecatedKnown = true; } return mIsDeprecated; } public TagInfo[] deprecatedTags() { // Should we also do the interfaces? return comment().deprecatedTags(); } public ArrayList<MethodInfo> methods() { if (mMethods == null) { TreeMap<String, MethodInfo> all = new TreeMap<String, MethodInfo>(); ArrayList<ClassInfo> interfaces = interfaces(); for (ClassInfo iface : interfaces) { if (iface != null) { for (MethodInfo method : iface.methods()) { all.put(method.getHashableName(), method); } } } ClassInfo superclass = superclass(); if (superclass != null) { for (MethodInfo method : superclass.methods()) { all.put(method.getHashableName(), method); } } for (MethodInfo method : selfMethods()) { all.put(method.getHashableName(), method); } mMethods = new ArrayList<MethodInfo>(all.values()); Collections.sort(mMethods, MethodInfo.comparator); } return mMethods; } public ArrayList<MethodInfo> annotationElements() { return mAnnotationElements; } public ArrayList<AnnotationInstanceInfo> annotations() { return mAnnotations; } private static void addFields(ClassInfo cl, TreeMap<String, FieldInfo> all) { for (FieldInfo field : cl.fields()) { all.put(field.name(), field); } } public ArrayList<FieldInfo> fields() { if (mFields == null) { TreeMap<String, FieldInfo> all = new TreeMap<String, FieldInfo>(); for (ClassInfo iface : interfaces()) { addFields(iface, all); } ClassInfo superclass = superclass(); if (superclass != null) { addFields(superclass, all); } for (FieldInfo field : selfFields()) { if (!field.isHiddenOrRemoved()) { all.put(field.name(), field); } } for (FieldInfo enumConst : mEnumConstants) { if (!enumConst.isHiddenOrRemoved()) { all.put(enumConst.name(), enumConst); } } mFields = new ArrayList<FieldInfo>(all.values()); } return mFields; } public void gatherFields(ClassInfo owner, ClassInfo cl, HashMap<String, FieldInfo> fields) { for (FieldInfo f : cl.selfFields()) { if (f.checkLevel()) { fields.put(f.name(), f.cloneForClass(owner)); } } } public ArrayList<FieldInfo> selfFields() { if (mSelfFields == null) { HashMap<String, FieldInfo> fields = new HashMap<String, FieldInfo>(); // our hidden parents if (mRealSuperclass != null && !mRealSuperclass.checkLevel()) { gatherFields(this, mRealSuperclass, fields); } for (ClassInfo iface : mRealInterfaces) { if (!iface.checkLevel()) { gatherFields(this, iface, fields); } } for (FieldInfo f : mAllSelfFields) { if (!f.isHiddenOrRemoved()) { fields.put(f.name(), f); } } mSelfFields = new ArrayList<FieldInfo>(fields.values()); Collections.sort(mSelfFields, FieldInfo.comparator); } return mSelfFields; } public ArrayList<FieldInfo> allSelfFields() { return mAllSelfFields; } private void gatherMethods(ClassInfo owner, ClassTypePair ctp, HashMap<String, MethodInfo> methods) { for (MethodInfo m : ctp.classInfo().selfMethods()) { if (m.checkLevel()) { methods.put(m.name() + m.signature(), m.cloneForClass(owner, ctp.getTypeArgumentMapping())); } } } public ArrayList<MethodInfo> selfMethods() { if (mSelfMethods == null) { HashMap<String, MethodInfo> methods = new HashMap<String, MethodInfo>(); // our hidden parents for (ClassTypePair ctp : superClassesWithTypes()) { // this class is included in this list, so skip it! if (ctp.classInfo() != this) { if (ctp.classInfo().checkLevel()) { break; } gatherMethods(this, ctp, methods); } } for (ClassTypePair ctp : justMyInterfacesWithTypes(Collections.<String, TypeInfo>emptyMap())) { if (!ctp.classInfo().checkLevel()) { gatherMethods(this, ctp, methods); } } // mine if (mAllSelfMethods != null) { for (MethodInfo m : mAllSelfMethods) { if (m.checkLevel()) { methods.put(m.name() + m.signature(), m); } } } // sort it mSelfMethods = new ArrayList<MethodInfo>(methods.values()); Collections.sort(mSelfMethods, MethodInfo.comparator); } return mSelfMethods; } public ArrayList<MethodInfo> allSelfMethods() { return mAllSelfMethods; } /** * @param removedMethods the removed methods regardless of access levels. */ public void setRemovedMethods(List<MethodInfo> removedMethods) { Collections.sort(removedMethods, MethodInfo.comparator); mRemovedMethods = Collections.unmodifiableList(removedMethods); } /** * @param allMethods all methods regardless of access levels. Selects the * removed, public/protected ones and store them. If a class is removed, all its members * are removed, even if the member may not have a @removed tag. */ public void setRemovedSelfMethods(List<MethodInfo> allMethods) { List<MethodInfo> removedSelfMethods = new ArrayList<MethodInfo>(); for (MethodInfo method : allMethods) { if ((this.isRemoved() || method.isRemoved()) && (method.isPublic() || method.isProtected()) && (this.isPublic() || this.isProtected()) && (method.findOverriddenMethod(method.name(), method.signature()) == null)) { removedSelfMethods.add(method); } } Collections.sort(removedSelfMethods, MethodInfo.comparator); mRemovedSelfMethods = Collections.unmodifiableList(removedSelfMethods); } /** * @param allCtors all constructors regardless of access levels. * But only the public/protected removed constructors will be stored by the method. * Removed constructors should never be deleted from source code because * they were once public API. */ public void setRemovedConstructors(List<MethodInfo> allCtors) { List<MethodInfo> ctors = new ArrayList<MethodInfo>(); for (MethodInfo ctor : allCtors) { if ((this.isRemoved() || ctor.isRemoved()) && (ctor.isPublic() || ctor.isProtected()) && (this.isPublic() || this.isProtected())) { ctors.add(ctor); } } Collections.sort(ctors, MethodInfo.comparator); mRemovedConstructors = Collections.unmodifiableList(ctors); } /** * @param allFields all fields regardless of access levels. Selects the * removed, public/protected ones and store them. If a class is removed, all its members * are removed, even if the member may not have a @removed tag. */ public void setRemovedSelfFields(List<FieldInfo> allFields) { List<FieldInfo> fields = new ArrayList<FieldInfo>(); for (FieldInfo field : allFields) { if ((this.isRemoved() || field.isRemoved()) && (field.isPublic() || field.isProtected()) && (this.isPublic() || this.isProtected())) { fields.add(field); } } Collections.sort(fields, FieldInfo.comparator); mRemovedSelfFields = Collections.unmodifiableList(fields); } /** * @param allEnumConstants all enum constants regardless of access levels. Selects the * removed, public/protected ones and store them. If a class is removed, all its members * are removed, even if the member may not have a @removed tag. */ public void setRemovedEnumConstants(List<FieldInfo> allEnumConstants) { List<FieldInfo> enums = new ArrayList<FieldInfo>(); for (FieldInfo field : allEnumConstants) { if ((this.isRemoved() || field.isRemoved()) && (field.isPublic() || field.isProtected()) && (this.isPublic() || this.isProtected())) { enums.add(field); } } Collections.sort(enums, FieldInfo.comparator); mRemovedEnumConstants = Collections.unmodifiableList(enums); } /** * @return all methods that are marked as removed, regardless of access levels. * The returned list is sorted and unmodifiable. */ public List<MethodInfo> getRemovedMethods() { return mRemovedMethods; } /** * @return all public/protected methods that are removed. @removed methods should never be * deleted from source code because they were once public API. Methods that override * a parent method will not be included, because deleting them does not break the API. */ public List<MethodInfo> getRemovedSelfMethods() { return mRemovedSelfMethods; } /** * @return all public constructors that are removed. * removed constructors should never be deleted from source code because they * were once public API. * The returned list is sorted and unmodifiable. */ public List<MethodInfo> getRemovedConstructors() { return mRemovedConstructors; } /** * @return all public/protected fields that are removed. * removed members should never be deleted from source code because they were once public API. * The returned list is sorted and unmodifiable. */ public List<FieldInfo> getRemovedSelfFields() { return mRemovedSelfFields; } /** * @return all public/protected enumConstants that are removed. * removed members should never be deleted from source code * because they were once public API. * The returned list is sorted and unmodifiable. */ public List<FieldInfo> getRemovedSelfEnumConstants() { return mRemovedEnumConstants; } /** * @return true if this class contains any self members that are removed */ public boolean hasRemovedSelfMembers() { List<FieldInfo> removedSelfFields = getRemovedSelfFields(); List<FieldInfo> removedSelfEnumConstants = getRemovedSelfEnumConstants(); List<MethodInfo> removedSelfMethods = getRemovedSelfMethods(); List<MethodInfo> removedConstructors = getRemovedConstructors(); if (removedSelfFields.size() + removedSelfEnumConstants.size() + removedSelfMethods.size() + removedConstructors.size() == 0) { return false; } else { return true; } } public void addMethod(MethodInfo method) { mApiCheckMethods.put(method.getHashableName(), method); mAllSelfMethods.add(method); mSelfMethods = null; // flush this, hopefully it hasn't been used yet. } public void addAnnotationElement(MethodInfo method) { mAnnotationElements.add(method); } // Called by PackageInfo when a ClassInfo is added to a package. // This is needed because ApiCheck uses PackageInfo.addClass // rather than using setContainingPackage to dispatch to the // appropriate method. TODO: move ApiCheck away from addClass. void setPackage(PackageInfo pkg) { mContainingPackage = pkg; } public void setContainingPackage(PackageInfo pkg) { mContainingPackage = pkg; if (mContainingPackage != null) { if (mIsEnum) { mContainingPackage.addEnum(this); } else if (mIsInterface) { mContainingPackage.addInterface(this); } else { mContainingPackage.addOrdinaryClass(this); } } } public ArrayList<AttributeInfo> selfAttributes() { if (mSelfAttributes == null) { TreeMap<FieldInfo, AttributeInfo> attrs = new TreeMap<FieldInfo, AttributeInfo>(); // the ones in the class comment won't have any methods for (AttrTagInfo tag : comment().attrTags()) { FieldInfo field = tag.reference(); if (field != null) { AttributeInfo attr = attrs.get(field); if (attr == null) { attr = new AttributeInfo(this, field); attrs.put(field, attr); } tag.setAttribute(attr); } } // in the methods for (MethodInfo m : selfMethods()) { for (AttrTagInfo tag : m.comment().attrTags()) { FieldInfo field = tag.reference(); if (field != null) { AttributeInfo attr = attrs.get(field); if (attr == null) { attr = new AttributeInfo(this, field); attrs.put(field, attr); } tag.setAttribute(attr); attr.methods.add(m); } } } // constructors too for (MethodInfo m : constructors()) { for (AttrTagInfo tag : m.comment().attrTags()) { FieldInfo field = tag.reference(); if (field != null) { AttributeInfo attr = attrs.get(field); if (attr == null) { attr = new AttributeInfo(this, field); attrs.put(field, attr); } tag.setAttribute(attr); attr.methods.add(m); } } } mSelfAttributes = new ArrayList<AttributeInfo>(attrs.values()); Collections.sort(mSelfAttributes, AttributeInfo.comparator); } return mSelfAttributes; } public ArrayList<FieldInfo> enumConstants() { return mEnumConstants; } public ClassInfo superclass() { if (!mSuperclassInit) { if (this.checkLevel()) { // rearrange our little inheritance hierarchy, because we need to hide classes that // don't pass checkLevel ClassInfo superclass = mRealSuperclass; while (superclass != null && !superclass.checkLevel()) { superclass = superclass.mRealSuperclass; } mSuperclass = superclass; } else { mSuperclass = mRealSuperclass; } } return mSuperclass; } public ClassInfo realSuperclass() { return mRealSuperclass; } /** * always the real superclass, not the collapsed one we get through superclass(), also has the * type parameter info if it's generic. */ public TypeInfo superclassType() { return mRealSuperclassType; } public TypeInfo asTypeInfo() { return mTypeInfo; } ArrayList<TypeInfo> interfaceTypes() { ArrayList<TypeInfo> types = new ArrayList<TypeInfo>(); for (ClassInfo iface : interfaces()) { types.add(iface.asTypeInfo()); } return types; } public String htmlPage() { String s = containingPackage().name(); s = s.replace('.', '/'); s += '/'; s += name(); s += ".html"; s = Doclava.javadocDir + s; return s; } /** Even indirectly */ public boolean isDerivedFrom(ClassInfo cl) { return isDerivedFrom(cl.qualifiedName()); } /** Even indirectly */ public boolean isDerivedFrom(String qualifiedName) { ClassInfo dad = this.superclass(); if (dad != null) { if (dad.mQualifiedName.equals(qualifiedName)) { return true; } else { if (dad.isDerivedFrom(qualifiedName)) { return true; } } } for (ClassInfo iface : interfaces()) { if (iface.mQualifiedName.equals(qualifiedName)) { return true; } else { if (iface.isDerivedFrom(qualifiedName)) { return true; } } } return false; } public void makeKeywordEntries(List<KeywordEntry> keywords) { if (!checkLevel()) { return; } String htmlPage = htmlPage(); String qualifiedName = qualifiedName(); keywords.add(new KeywordEntry(name(), htmlPage, "class in " + containingPackage().name())); ArrayList<FieldInfo> fields = selfFields(); //ArrayList<FieldInfo> enumConstants = enumConstants(); ArrayList<MethodInfo> ctors = constructors(); ArrayList<MethodInfo> methods = selfMethods(); // enum constants for (FieldInfo field : enumConstants()) { if (field.checkLevel()) { keywords.add(new KeywordEntry(field.name(), htmlPage + "#" + field.anchor(), "enum constant in " + qualifiedName)); } } // constants for (FieldInfo field : fields) { if (field.isConstant() && field.checkLevel()) { keywords.add(new KeywordEntry(field.name(), htmlPage + "#" + field.anchor(), "constant in " + qualifiedName)); } } // fields for (FieldInfo field : fields) { if (!field.isConstant() && field.checkLevel()) { keywords.add(new KeywordEntry(field.name(), htmlPage + "#" + field.anchor(), "field in " + qualifiedName)); } } // public constructors for (MethodInfo m : ctors) { if (m.isPublic() && m.checkLevel()) { keywords.add(new KeywordEntry(m.prettySignature(), htmlPage + "#" + m.anchor(), "constructor in " + qualifiedName)); } } // protected constructors if (Doclava.checkLevel(Doclava.SHOW_PROTECTED)) { for (MethodInfo m : ctors) { if (m.isProtected() && m.checkLevel()) { keywords.add(new KeywordEntry(m.prettySignature(), htmlPage + "#" + m.anchor(), "constructor in " + qualifiedName)); } } } // package private constructors if (Doclava.checkLevel(Doclava.SHOW_PACKAGE)) { for (MethodInfo m : ctors) { if (m.isPackagePrivate() && m.checkLevel()) { keywords.add(new KeywordEntry(m.prettySignature(), htmlPage + "#" + m.anchor(), "constructor in " + qualifiedName)); } } } // private constructors if (Doclava.checkLevel(Doclava.SHOW_PRIVATE)) { for (MethodInfo m : ctors) { if (m.isPrivate() && m.checkLevel()) { keywords.add(new KeywordEntry(m.name() + m.prettySignature(), htmlPage + "#" + m.anchor(), "constructor in " + qualifiedName)); } } } // public methods for (MethodInfo m : methods) { if (m.isPublic() && m.checkLevel()) { keywords.add(new KeywordEntry(m.name() + m.prettySignature(), htmlPage + "#" + m.anchor(), "method in " + qualifiedName)); } } // protected methods if (Doclava.checkLevel(Doclava.SHOW_PROTECTED)) { for (MethodInfo m : methods) { if (m.isProtected() && m.checkLevel()) { keywords.add(new KeywordEntry(m.name() + m.prettySignature(), htmlPage + "#" + m.anchor(), "method in " + qualifiedName)); } } } // package private methods if (Doclava.checkLevel(Doclava.SHOW_PACKAGE)) { for (MethodInfo m : methods) { if (m.isPackagePrivate() && m.checkLevel()) { keywords.add(new KeywordEntry(m.name() + m.prettySignature(), htmlPage + "#" + m.anchor(), "method in " + qualifiedName)); } } } // private methods if (Doclava.checkLevel(Doclava.SHOW_PRIVATE)) { for (MethodInfo m : methods) { if (m.isPrivate() && m.checkLevel()) { keywords.add(new KeywordEntry(m.name() + m.prettySignature(), htmlPage + "#" + m.anchor(), "method in " + qualifiedName)); } } } } public void makeLink(Data data, String base) { data.setValue(base + ".label", this.name()); if (!this.isPrimitive() && this.isIncluded() && this.checkLevel()) { data.setValue(base + ".link", this.htmlPage()); } } public static void makeLinkListHDF(Data data, String base, ClassInfo[] classes) { final int N = classes.length; for (int i = 0; i < N; i++) { ClassInfo cl = classes[i]; if (cl.checkLevel()) { cl.asTypeInfo().makeHDF(data, base + "." + i); } } } /** * Used in lists of this class (packages, nested classes, known subclasses) */ public void makeShortDescrHDF(Data data, String base) { mTypeInfo.makeHDF(data, base + ".type"); data.setValue(base + ".kind", this.kind()); TagInfo.makeHDF(data, base + ".shortDescr", this.firstSentenceTags()); TagInfo.makeHDF(data, base + ".deprecated", deprecatedTags()); data.setValue(base + ".since", getSince()); if (isDeprecated()) { data.setValue(base + ".deprecatedsince", getDeprecatedSince()); } ArrayList<AnnotationInstanceInfo> showAnnos = getShowAnnotationsIncludeOuters(); AnnotationInstanceInfo.makeLinkListHDF( data, base + ".showAnnotations", showAnnos.toArray(new AnnotationInstanceInfo[showAnnos.size()])); setFederatedReferences(data, base); } /** * Turns into the main class page */ public void makeHDF(Data data) { int i, j, n; String name = name(); String qualified = qualifiedName(); ArrayList<AttributeInfo> selfAttributes = selfAttributes(); ArrayList<MethodInfo> methods = selfMethods(); ArrayList<FieldInfo> fields = selfFields(); ArrayList<FieldInfo> enumConstants = enumConstants(); ArrayList<MethodInfo> ctors = constructors(); ArrayList<ClassInfo> inners = innerClasses(); // class name mTypeInfo.makeHDF(data, "class.type"); mTypeInfo.makeQualifiedHDF(data, "class.qualifiedType"); data.setValue("class.name", name); data.setValue("class.qualified", qualified); if (isProtected()) { data.setValue("class.scope", "protected"); } else if (isPublic()) { data.setValue("class.scope", "public"); } if (isStatic()) { data.setValue("class.static", "static"); } if (isFinal()) { data.setValue("class.final", "final"); } if (isAbstract() && !isInterface()) { data.setValue("class.abstract", "abstract"); } int numAnnotationDocumentation = 0; for (AnnotationInstanceInfo aii : annotations()) { String annotationDocumentation = Doclava.getDocumentationStringForAnnotation( aii.type().qualifiedName()); if (annotationDocumentation != null) { data.setValue("class.annotationdocumentation." + numAnnotationDocumentation + ".text", annotationDocumentation); numAnnotationDocumentation++; } } ArrayList<AnnotationInstanceInfo> showAnnos = getShowAnnotationsIncludeOuters(); AnnotationInstanceInfo.makeLinkListHDF( data, "class.showAnnotations", showAnnos.toArray(new AnnotationInstanceInfo[showAnnos.size()])); // class info String kind = kind(); if (kind != null) { data.setValue("class.kind", kind); } data.setValue("class.since", getSince()); if (isDeprecated()) { data.setValue("class.deprecatedsince", getDeprecatedSince()); } setFederatedReferences(data, "class"); // the containing package -- note that this can be passed to type_link, // but it also contains the list of all of the packages containingPackage().makeClassLinkListHDF(data, "class.package"); // inheritance hierarchy List<ClassTypePair> ctplist = superClassesWithTypes(); n = ctplist.size(); for (i = 0; i < ctplist.size(); i++) { // go in reverse order ClassTypePair ctp = ctplist.get(n - i - 1); if (ctp.classInfo().checkLevel()) { ctp.typeInfo().makeQualifiedHDF(data, "class.inheritance." + i + ".class"); ctp.typeInfo().makeHDF(data, "class.inheritance." + i + ".short_class"); j = 0; for (ClassTypePair t : ctp.classInfo().interfacesWithTypes()) { t.typeInfo().makeHDF(data, "class.inheritance." + i + ".interfaces." + j); j++; } } } // class description TagInfo.makeHDF(data, "class.descr", inlineTags()); TagInfo.makeHDF(data, "class.seeAlso", comment().seeTags()); TagInfo.makeHDF(data, "class.deprecated", deprecatedTags()); // known subclasses TreeMap<String, ClassInfo> direct = new TreeMap<String, ClassInfo>(); TreeMap<String, ClassInfo> indirect = new TreeMap<String, ClassInfo>(); ClassInfo[] all = Converter.rootClasses(); for (ClassInfo cl : all) { if (cl.superclass() != null && cl.superclass().equals(this)) { direct.put(cl.name(), cl); } else if (cl.isDerivedFrom(this)) { indirect.put(cl.name(), cl); } } // direct i = 0; for (ClassInfo cl : direct.values()) { if (cl.checkLevel()) { cl.makeShortDescrHDF(data, "class.subclasses.direct." + i); } i++; } // indirect i = 0; for (ClassInfo cl : indirect.values()) { if (cl.checkLevel()) { cl.makeShortDescrHDF(data, "class.subclasses.indirect." + i); } i++; } // hide special cases if ("java.lang.Object".equals(qualified) || "java.io.Serializable".equals(qualified)) { data.setValue("class.subclasses.hidden", "1"); } else { data.setValue("class.subclasses.hidden", "0"); } // nested classes i = 0; for (ClassInfo inner : inners) { if (inner.checkLevel()) { inner.makeShortDescrHDF(data, "class.inners." + i); } i++; } // enum constants i = 0; for (FieldInfo field : enumConstants) { field.makeHDF(data, "class.enumConstants." + i); i++; } // constants i = 0; for (FieldInfo field : fields) { if (field.isConstant()) { field.makeHDF(data, "class.constants." + i); i++; } } // fields i = 0; for (FieldInfo field : fields) { if (!field.isConstant()) { field.makeHDF(data, "class.fields." + i); i++; } } // public constructors i = 0; for (MethodInfo ctor : ctors) { if (ctor.isPublic()) { ctor.makeHDF(data, "class.ctors.public." + i); i++; } } // protected constructors if (Doclava.checkLevel(Doclava.SHOW_PROTECTED)) { i = 0; for (MethodInfo ctor : ctors) { if (ctor.isProtected()) { ctor.makeHDF(data, "class.ctors.protected." + i); i++; } } } // package private constructors if (Doclava.checkLevel(Doclava.SHOW_PACKAGE)) { i = 0; for (MethodInfo ctor : ctors) { if (ctor.isPackagePrivate()) { ctor.makeHDF(data, "class.ctors.package." + i); i++; } } } // private constructors if (Doclava.checkLevel(Doclava.SHOW_PRIVATE)) { i = 0; for (MethodInfo ctor : ctors) { if (ctor.isPrivate()) { ctor.makeHDF(data, "class.ctors.private." + i); i++; } } } // public methods i = 0; for (MethodInfo method : methods) { if (method.isPublic()) { method.makeHDF(data, "class.methods.public." + i); i++; } } // protected methods if (Doclava.checkLevel(Doclava.SHOW_PROTECTED)) { i = 0; for (MethodInfo method : methods) { if (method.isProtected()) { method.makeHDF(data, "class.methods.protected." + i); i++; } } } // package private methods if (Doclava.checkLevel(Doclava.SHOW_PACKAGE)) { i = 0; for (MethodInfo method : methods) { if (method.isPackagePrivate()) { method.makeHDF(data, "class.methods.package." + i); i++; } } } // private methods if (Doclava.checkLevel(Doclava.SHOW_PRIVATE)) { i = 0; for (MethodInfo method : methods) { if (method.isPrivate()) { method.makeHDF(data, "class.methods.private." + i); i++; } } } // xml attributes i = 0; for (AttributeInfo attr : selfAttributes) { if (attr.checkLevel()) { attr.makeHDF(data, "class.attrs." + i); i++; } } // inherited methods Iterator<ClassTypePair> superclassesItr = superClassesWithTypes().iterator(); superclassesItr.next(); // skip the first one, which is the current class ClassTypePair superCtp; i = 0; while (superclassesItr.hasNext()) { superCtp = superclassesItr.next(); if (superCtp.classInfo().checkLevel()) { makeInheritedHDF(data, i, superCtp); i++; } } Iterator<ClassTypePair> interfacesItr = allInterfacesWithTypes().iterator(); while (interfacesItr.hasNext()) { superCtp = interfacesItr.next(); if (superCtp.classInfo().checkLevel()) { makeInheritedHDF(data, i, superCtp); i++; } } } private static void makeInheritedHDF(Data data, int index, ClassTypePair ctp) { int i; String base = "class.inherited." + index; data.setValue(base + ".qualified", ctp.classInfo().qualifiedName()); if (ctp.classInfo().checkLevel()) { data.setValue(base + ".link", ctp.classInfo().htmlPage()); } String kind = ctp.classInfo().kind(); if (kind != null) { data.setValue(base + ".kind", kind); } if (ctp.classInfo().mIsIncluded) { data.setValue(base + ".included", "true"); } else { Doclava.federationTagger.tagAll(new ClassInfo[] {ctp.classInfo()}); if (!ctp.classInfo().getFederatedReferences().isEmpty()) { FederatedSite site = ctp.classInfo().getFederatedReferences().iterator().next(); data.setValue(base + ".link", site.linkFor(ctp.classInfo().htmlPage())); data.setValue(base + ".federated", site.name()); } } // xml attributes i = 0; for (AttributeInfo attr : ctp.classInfo().selfAttributes()) { attr.makeHDF(data, base + ".attrs." + i); i++; } // methods i = 0; for (MethodInfo method : ctp.classInfo().selfMethods()) { method.makeHDF(data, base + ".methods." + i, ctp.getTypeArgumentMapping()); i++; } // fields i = 0; for (FieldInfo field : ctp.classInfo().selfFields()) { if (!field.isConstant()) { field.makeHDF(data, base + ".fields." + i); i++; } } // constants i = 0; for (FieldInfo field : ctp.classInfo().selfFields()) { if (field.isConstant()) { field.makeHDF(data, base + ".constants." + i); i++; } } } @Override public boolean isHidden() { if (mHidden == null) { mHidden = isHiddenImpl(); } return mHidden; } /** * @return true if the containing package has @hide comment, or an ancestor * class of this class is hidden, or this class has @hide comment. */ public boolean isHiddenImpl() { ClassInfo cl = this; while (cl != null) { if (cl.hasShowAnnotation()) { return false; } PackageInfo pkg = cl.containingPackage(); if (pkg != null && pkg.hasHideComment()) { return true; } if (cl.comment().isHidden()) { return true; } cl = cl.containingClass(); } return false; } @Override public boolean isRemoved() { if (mRemoved == null) { mRemoved = isRemovedImpl(); } return mRemoved; } /** * @return true if the containing package has @removed comment, or an ancestor * class of this class is removed, or this class has @removed comment. */ public boolean isRemovedImpl() { ClassInfo cl = this; while (cl != null) { if (cl.hasShowAnnotation()) { return false; } PackageInfo pkg = cl.containingPackage(); if (pkg != null && pkg.hasRemovedComment()) { return true; } if (cl.comment().isRemoved()) { return true; } cl = cl.containingClass(); } return false; } @Override public boolean isHiddenOrRemoved() { return isHidden() || isRemoved(); } public boolean hasShowAnnotation() { return mShowAnnotations != null && mShowAnnotations.size() > 0; } public ArrayList<AnnotationInstanceInfo> showAnnotations() { return mShowAnnotations; } public ArrayList<AnnotationInstanceInfo> getShowAnnotationsIncludeOuters() { ArrayList<AnnotationInstanceInfo> allAnnotations = new ArrayList<AnnotationInstanceInfo>(); ClassInfo cl = this; while (cl != null) { if (cl.showAnnotations() != null) { // Don't allow duplicates into the merged list for (AnnotationInstanceInfo newAii : cl.showAnnotations()) { boolean addIt = true; for (AnnotationInstanceInfo existingAii : allAnnotations) { if (existingAii.type().name() == newAii.type().name()) { addIt = false; break; } } if (addIt) { allAnnotations.add(newAii); } } } cl = cl.containingClass(); } return allAnnotations; } private MethodInfo matchMethod(ArrayList<MethodInfo> methods, String name, String[] params, String[] dimensions, boolean varargs) { for (MethodInfo method : methods) { if (method.name().equals(name)) { if (params == null) { return method; } else { if (method.matchesParams(params, dimensions, varargs)) { return method; } } } } return null; } public MethodInfo findMethod(String name, String[] params, String[] dimensions, boolean varargs) { // first look on our class, and our superclasses // for methods MethodInfo rv; rv = matchMethod(methods(), name, params, dimensions, varargs); if (rv != null) { return rv; } // for constructors rv = matchMethod(constructors(), name, params, dimensions, varargs); if (rv != null) { return rv; } // then recursively look at our containing class ClassInfo containing = containingClass(); if (containing != null) { return containing.findMethod(name, params, dimensions, varargs); } return null; } public boolean supportsMethod(MethodInfo method) { for (MethodInfo m : methods()) { if (m.getHashableName().equals(method.getHashableName())) { return true; } } return false; } private ClassInfo searchInnerClasses(String[] nameParts, int index) { String part = nameParts[index]; ArrayList<ClassInfo> inners = mInnerClasses; for (ClassInfo in : inners) { String[] innerParts = in.nameParts(); if (part.equals(innerParts[innerParts.length - 1])) { if (index == nameParts.length - 1) { return in; } else { return in.searchInnerClasses(nameParts, index + 1); } } } return null; } public ClassInfo extendedFindClass(String className) { // ClassDoc.findClass has this bug that we're working around here: // If you have a class PackageManager with an inner class PackageInfo // and you call it with "PackageInfo" it doesn't find it. return searchInnerClasses(className.split("\\."), 0); } public ClassInfo findClass(String className) { return Converter.obtainClass(mClass.findClass(className)); } public ClassInfo findInnerClass(String className) { // ClassDoc.findClass won't find inner classes. To deal with that, // we try what they gave us first, but if that didn't work, then // we see if there are any periods in className, and start searching // from there. String[] nodes = className.split("\\."); ClassDoc cl = mClass; int N = nodes.length; for (int i = 0; i < N; ++i) { final String n = nodes[i]; if (n.isEmpty() && i == 0) { // We skip over an empty classname component if it's at location 0. This is // to deal with names like ".Inner". java7 will return a bogus ClassInfo when // we call "findClass("") and the next iteration of the loop will throw a // runtime exception. continue; } cl = cl.findClass(n); if (cl == null) { return null; } } return Converter.obtainClass(cl); } public FieldInfo findField(String name) { // first look on our class, and our superclasses for (FieldInfo f : fields()) { if (f.name().equals(name)) { return f; } } // then look at our enum constants (these are really fields, maybe // they should be mixed into fields(). not sure) for (FieldInfo f : enumConstants()) { if (f.name().equals(name)) { return f; } } // then recursively look at our containing class ClassInfo containing = containingClass(); if (containing != null) { return containing.findField(name); } return null; } public static ClassInfo[] sortByName(ClassInfo[] classes) { int i; Sorter[] sorted = new Sorter[classes.length]; for (i = 0; i < sorted.length; i++) { ClassInfo cl = classes[i]; sorted[i] = new Sorter(cl.name(), cl); } Arrays.sort(sorted); ClassInfo[] rv = new ClassInfo[classes.length]; for (i = 0; i < rv.length; i++) { rv[i] = (ClassInfo) sorted[i].data; } return rv; } public boolean equals(ClassInfo that) { if (that != null) { return this.qualifiedName().equals(that.qualifiedName()); } else { return false; } } public void setNonWrittenConstructors(ArrayList<MethodInfo> nonWritten) { mNonWrittenConstructors = nonWritten; } public ArrayList<MethodInfo> getNonWrittenConstructors() { return mNonWrittenConstructors; } public String kind() { if (isOrdinaryClass()) { return "class"; } else if (isInterface()) { return "interface"; } else if (isEnum()) { return "enum"; } else if (isError()) { return "class"; } else if (isException()) { return "class"; } else if (isAnnotation()) { return "@interface"; } return null; } public String scope() { if (isPublic()) { return "public"; } else if (isProtected()) { return "protected"; } else if (isPackagePrivate()) { return ""; } else if (isPrivate()) { return "private"; } else { throw new RuntimeException("invalid scope for object " + this); } } public void setHiddenMethods(ArrayList<MethodInfo> mInfo) { mHiddenMethods = mInfo; } public ArrayList<MethodInfo> getHiddenMethods() { return mHiddenMethods; } @Override public String toString() { return this.qualifiedName(); } public void setReasonIncluded(String reason) { mReasonIncluded = reason; } public String getReasonIncluded() { return mReasonIncluded; } private ClassDoc mClass; // ctor private boolean mIsPublic; private boolean mIsProtected; private boolean mIsPackagePrivate; private boolean mIsPrivate; private boolean mIsStatic; private boolean mIsInterface; private boolean mIsAbstract; private boolean mIsOrdinaryClass; private boolean mIsException; private boolean mIsError; private boolean mIsEnum; private boolean mIsAnnotation; private boolean mIsFinal; private boolean mIsIncluded; private String mName; private String mQualifiedName; private String mQualifiedTypeName; private boolean mIsPrimitive; private TypeInfo mTypeInfo; private String[] mNameParts; // init private ArrayList<ClassInfo> mRealInterfaces = new ArrayList<ClassInfo>(); private ArrayList<ClassInfo> mInterfaces; private ArrayList<TypeInfo> mRealInterfaceTypes; private ArrayList<ClassInfo> mInnerClasses; // mAllConstructors will not contain *all* constructors. Only the constructors that pass // checkLevel. @see {@link Converter#convertMethods(ConstructorDoc[])} private ArrayList<MethodInfo> mAllConstructors = new ArrayList<MethodInfo>(); // mAllSelfMethods will not contain *all* self methods. Only the methods that pass // checkLevel. @see {@link Converter#convertMethods(MethodDoc[])} private ArrayList<MethodInfo> mAllSelfMethods = new ArrayList<MethodInfo>(); private ArrayList<MethodInfo> mAnnotationElements = new ArrayList<MethodInfo>(); // if this class is an annotation private ArrayList<FieldInfo> mAllSelfFields = new ArrayList<FieldInfo>(); private ArrayList<FieldInfo> mEnumConstants = new ArrayList<FieldInfo>(); private PackageInfo mContainingPackage; private ClassInfo mContainingClass; private ClassInfo mRealSuperclass; private TypeInfo mRealSuperclassType; private ClassInfo mSuperclass; private ArrayList<AnnotationInstanceInfo> mAnnotations; private ArrayList<AnnotationInstanceInfo> mShowAnnotations; private boolean mSuperclassInit; private boolean mDeprecatedKnown; // lazy private ArrayList<ClassTypePair> mSuperclassesWithTypes; private ArrayList<ClassTypePair> mInterfacesWithTypes; private ArrayList<ClassTypePair> mAllInterfacesWithTypes; private ArrayList<MethodInfo> mConstructors; private ArrayList<ClassInfo> mRealInnerClasses; private ArrayList<MethodInfo> mSelfMethods; private ArrayList<FieldInfo> mSelfFields; private ArrayList<AttributeInfo> mSelfAttributes; private ArrayList<MethodInfo> mMethods; private ArrayList<FieldInfo> mFields; private ArrayList<TypeInfo> mTypeParameters; private ArrayList<MethodInfo> mHiddenMethods; private Boolean mHidden = null; private Boolean mRemoved = null; private Boolean mCheckLevel = null; private String mReasonIncluded; private ArrayList<MethodInfo> mNonWrittenConstructors; private boolean mIsDeprecated; // TODO: Temporary members from apicheck migration. private HashMap<String, MethodInfo> mApiCheckConstructors = new HashMap<String, MethodInfo>(); private HashMap<String, MethodInfo> mApiCheckMethods = new HashMap<String, MethodInfo>(); private HashMap<String, FieldInfo> mApiCheckFields = new HashMap<String, FieldInfo>(); private HashMap<String, FieldInfo> mApiCheckEnumConstants = new HashMap<String, FieldInfo>(); // Resolutions private ArrayList<Resolution> mResolutions; private List<MethodInfo> mRemovedConstructors; // immutable after you set its value. // @removed self methods that do not override any parent methods private List<MethodInfo> mRemovedSelfMethods; // immutable after you set its value. private List<MethodInfo> mRemovedMethods; // immutable after you set its value. private List<FieldInfo> mRemovedSelfFields; // immutable after you set its value. private List<FieldInfo> mRemovedEnumConstants; // immutable after you set its value. /** * Returns true if {@code cl} implements the interface {@code iface} either by either being that * interface, implementing that interface or extending a type that implements the interface. */ public boolean implementsInterface(String iface) { if (qualifiedName().equals(iface)) { return true; } for (ClassInfo clImplements : realInterfaces()) { if (clImplements.implementsInterface(iface)) { return true; } } if (mSuperclass != null && mSuperclass.implementsInterface(iface)) { return true; } return false; } /** * Returns true if {@code this} extends the class {@code ext}. */ public boolean extendsClass(String cl) { if (qualifiedName().equals(cl)) { return true; } if (mSuperclass != null && mSuperclass.extendsClass(cl)) { return true; } return false; } /** * Returns true if {@code this} is assignable to cl */ public boolean isAssignableTo(String cl) { return implementsInterface(cl) || extendsClass(cl); } public void addInterface(ClassInfo iface) { mRealInterfaces.add(iface); } public void addConstructor(MethodInfo ctor) { mApiCheckConstructors.put(ctor.getHashableName(), ctor); mAllConstructors.add(ctor); mConstructors = null; // flush this, hopefully it hasn't been used yet. } public void addField(FieldInfo field) { mApiCheckFields.put(field.name(), field); mAllSelfFields.add(field); mSelfFields = null; // flush this, hopefully it hasn't been used yet. } public void addEnumConstant(FieldInfo field) { mApiCheckEnumConstants.put(field.name(), field); mEnumConstants.add(field); } public void setSuperClass(ClassInfo superclass) { mRealSuperclass = superclass; mSuperclass = superclass; } public Map<String, MethodInfo> allConstructorsMap() { return mApiCheckConstructors; } public Map<String, FieldInfo> allFields() { return mApiCheckFields; } public Map<String, FieldInfo> allEnums() { return mApiCheckEnumConstants; } /** * Returns all methods defined directly in this class. For a list of all * methods supported by this class, see {@link #methods()}. */ public Map<String, MethodInfo> allMethods() { return mApiCheckMethods; } /** * Returns the class hierarchy for this class, starting with this class. */ public Iterable<ClassInfo> hierarchy() { List<ClassInfo> result = new ArrayList<ClassInfo>(4); for (ClassInfo c = this; c != null; c = c.mSuperclass) { result.add(c); } return result; } public String superclassName() { if (mSuperclass == null) { if (mQualifiedName.equals("java.lang.Object")) { return null; } throw new UnsupportedOperationException("Superclass not set for " + qualifiedName()); } return mSuperclass.mQualifiedName; } public void setAnnotations(ArrayList<AnnotationInstanceInfo> annotations) { mAnnotations = annotations; } public boolean isConsistent(ClassInfo cl) { return isConsistent(cl, null, null); } public boolean isConsistent(ClassInfo cl, List<MethodInfo> newCtors, List<MethodInfo> newMethods) { boolean consistent = true; boolean diffMode = (newCtors != null) && (newMethods != null); if (isInterface() != cl.isInterface()) { Errors.error(Errors.CHANGED_CLASS, cl.position(), "Class " + cl.qualifiedName() + " changed class/interface declaration"); consistent = false; } for (ClassInfo iface : mRealInterfaces) { if (!cl.implementsInterface(iface.mQualifiedName)) { Errors.error(Errors.REMOVED_INTERFACE, cl.position(), "Class " + qualifiedName() + " no longer implements " + iface); } } for (ClassInfo iface : cl.mRealInterfaces) { if (!implementsInterface(iface.mQualifiedName)) { Errors.error(Errors.ADDED_INTERFACE, cl.position(), "Added interface " + iface + " to class " + qualifiedName()); consistent = false; } } for (MethodInfo mInfo : mApiCheckMethods.values()) { if (cl.mApiCheckMethods.containsKey(mInfo.getHashableName())) { if (!mInfo.isConsistent(cl.mApiCheckMethods.get(mInfo.getHashableName()))) { consistent = false; } } else { /* * This class formerly provided this method directly, and now does not. Check our ancestry * to see if there's an inherited version that still fulfills the API requirement. */ MethodInfo mi = ClassInfo.overriddenMethod(mInfo, cl); if (mi == null) { mi = ClassInfo.interfaceMethod(mInfo, cl); } if (mi == null) { Errors.error(Errors.REMOVED_METHOD, mInfo.position(), "Removed public method " + mInfo.prettyQualifiedSignature()); consistent = false; } } } for (MethodInfo mInfo : cl.mApiCheckMethods.values()) { if (!mApiCheckMethods.containsKey(mInfo.getHashableName())) { /* * Similarly to the above, do not fail if this "new" method is really an override of an * existing superclass method. * But we should fail if this is overriding an abstract method, because method's * abstractness affects how users use it. See also Stubs.methodIsOverride(). */ MethodInfo mi = ClassInfo.overriddenMethod(mInfo, this); if (mi == null || mi.isAbstract() != mInfo.isAbstract()) { Errors.error(Errors.ADDED_METHOD, mInfo.position(), "Added public method " + mInfo.prettyQualifiedSignature()); if (diffMode) { newMethods.add(mInfo); } consistent = false; } } } if (diffMode) { Collections.sort(newMethods, MethodInfo.comparator); } for (MethodInfo mInfo : mApiCheckConstructors.values()) { if (cl.mApiCheckConstructors.containsKey(mInfo.getHashableName())) { if (!mInfo.isConsistent(cl.mApiCheckConstructors.get(mInfo.getHashableName()))) { consistent = false; } } else { Errors.error(Errors.REMOVED_METHOD, mInfo.position(), "Removed public constructor " + mInfo.prettyQualifiedSignature()); consistent = false; } } for (MethodInfo mInfo : cl.mApiCheckConstructors.values()) { if (!mApiCheckConstructors.containsKey(mInfo.getHashableName())) { Errors.error(Errors.ADDED_METHOD, mInfo.position(), "Added public constructor " + mInfo.prettyQualifiedSignature()); if (diffMode) { newCtors.add(mInfo); } consistent = false; } } if (diffMode) { Collections.sort(newCtors, MethodInfo.comparator); } for (FieldInfo mInfo : mApiCheckFields.values()) { if (cl.mApiCheckFields.containsKey(mInfo.name())) { if (!mInfo.isConsistent(cl.mApiCheckFields.get(mInfo.name()))) { consistent = false; } } else { Errors.error(Errors.REMOVED_FIELD, mInfo.position(), "Removed field " + mInfo.qualifiedName()); consistent = false; } } for (FieldInfo mInfo : cl.mApiCheckFields.values()) { if (!mApiCheckFields.containsKey(mInfo.name())) { Errors.error(Errors.ADDED_FIELD, mInfo.position(), "Added public field " + mInfo.qualifiedName()); consistent = false; } } for (FieldInfo info : mApiCheckEnumConstants.values()) { if (cl.mApiCheckEnumConstants.containsKey(info.name())) { if (!info.isConsistent(cl.mApiCheckEnumConstants.get(info.name()))) { consistent = false; } } else { Errors.error(Errors.REMOVED_FIELD, info.position(), "Removed enum constant " + info.qualifiedName()); consistent = false; } } for (FieldInfo info : cl.mApiCheckEnumConstants.values()) { if (!mApiCheckEnumConstants.containsKey(info.name())) { Errors.error(Errors.ADDED_FIELD, info.position(), "Added enum constant " + info.qualifiedName()); consistent = false; } } if (mIsAbstract != cl.mIsAbstract) { consistent = false; Errors.error(Errors.CHANGED_ABSTRACT, cl.position(), "Class " + cl.qualifiedName() + " changed abstract qualifier"); } if (!mIsFinal && cl.mIsFinal) { /* * It is safe to make a class final if it did not previously have any public * constructors because it was impossible for an application to create a subclass. */ if (mApiCheckConstructors.isEmpty()) { consistent = false; Errors.error(Errors.ADDED_FINAL_UNINSTANTIABLE, cl.position(), "Class " + cl.qualifiedName() + " added final qualifier but " + "was previously uninstantiable and therefore could not be subclassed"); } else { consistent = false; Errors.error(Errors.ADDED_FINAL, cl.position(), "Class " + cl.qualifiedName() + " added final qualifier"); } } else if (mIsFinal && !cl.mIsFinal) { consistent = false; Errors.error(Errors.REMOVED_FINAL, cl.position(), "Class " + cl.qualifiedName() + " removed final qualifier"); } if (mIsStatic != cl.mIsStatic) { consistent = false; Errors.error(Errors.CHANGED_STATIC, cl.position(), "Class " + cl.qualifiedName() + " changed static qualifier"); } if (!scope().equals(cl.scope())) { consistent = false; Errors.error(Errors.CHANGED_SCOPE, cl.position(), "Class " + cl.qualifiedName() + " scope changed from " + scope() + " to " + cl.scope()); } if (!isDeprecated() == cl.isDeprecated()) { consistent = false; Errors.error(Errors.CHANGED_DEPRECATED, cl.position(), "Class " + cl.qualifiedName() + " has changed deprecation state " + isDeprecated() + " --> " + cl.isDeprecated()); } if (superclassName() != null) { // java.lang.Object can't have a superclass. if (!cl.extendsClass(superclassName())) { consistent = false; Errors.error(Errors.CHANGED_SUPERCLASS, cl.position(), "Class " + qualifiedName() + " superclass changed from " + superclassName() + " to " + cl.superclassName()); } } return consistent; } // Find a superclass implementation of the given method based on the methods in mApiCheckMethods. public static MethodInfo overriddenMethod(MethodInfo candidate, ClassInfo newClassObj) { if (newClassObj == null) { return null; } for (MethodInfo mi : newClassObj.mApiCheckMethods.values()) { if (mi.matches(candidate)) { // found it return mi; } } // not found here. recursively search ancestors return ClassInfo.overriddenMethod(candidate, newClassObj.mSuperclass); } // Find a superinterface declaration of the given method. public static MethodInfo interfaceMethod(MethodInfo candidate, ClassInfo newClassObj) { if (newClassObj == null) { return null; } for (ClassInfo interfaceInfo : newClassObj.interfaces()) { for (MethodInfo mi : interfaceInfo.mApiCheckMethods.values()) { if (mi.matches(candidate)) { return mi; } } } return ClassInfo.interfaceMethod(candidate, newClassObj.mSuperclass); } public boolean hasConstructor(MethodInfo constructor) { String name = constructor.getHashableName(); for (MethodInfo ctor : mApiCheckConstructors.values()) { if (name.equals(ctor.getHashableName())) { return true; } } return false; } public void setTypeInfo(TypeInfo typeInfo) { mTypeInfo = typeInfo; } public TypeInfo type() { return mTypeInfo; } public void addInnerClass(ClassInfo innerClass) { if (mInnerClasses == null) { mInnerClasses = new ArrayList<ClassInfo>(); } mInnerClasses.add(innerClass); } public void setContainingClass(ClassInfo containingClass) { mContainingClass = containingClass; } public void setSuperclassType(TypeInfo superclassType) { mRealSuperclassType = superclassType; } public void printResolutions() { if (mResolutions == null || mResolutions.isEmpty()) { return; } System.out.println("Resolutions for Class " + mName + ":"); for (Resolution r : mResolutions) { System.out.println(r); } } public void addResolution(Resolution resolution) { if (mResolutions == null) { mResolutions = new ArrayList<Resolution>(); } mResolutions.add(resolution); } public boolean resolveResolutions() { ArrayList<Resolution> resolutions = mResolutions; mResolutions = new ArrayList<Resolution>(); boolean allResolved = true; for (Resolution resolution : resolutions) { StringBuilder qualifiedClassName = new StringBuilder(); InfoBuilder.resolveQualifiedName(resolution.getValue(), qualifiedClassName, resolution.getInfoBuilder()); // if we still couldn't resolve it, save it for the next pass if ("".equals(qualifiedClassName.toString())) { mResolutions.add(resolution); allResolved = false; } else if ("superclassQualifiedName".equals(resolution.getVariable())) { setSuperClass(InfoBuilder.Caches.obtainClass(qualifiedClassName.toString())); } else if ("interfaceQualifiedName".equals(resolution.getVariable())) { addInterface(InfoBuilder.Caches.obtainClass(qualifiedClassName.toString())); } } return allResolved; } }
31.412441
125
0.64175
fb7c5ab14d948ef843332a2dbac4fae34aac20d9
1,725
java
Java
src/test/java/com/chemistsmc/minigamesframework/TestHelper.java
ChemistsMC/MinigamesFramework
a314d8840af68ff210e72581542cd97c8abc45f4
[ "MIT" ]
1
2018-03-17T18:13:20.000Z
2018-03-17T18:13:20.000Z
src/test/java/com/chemistsmc/minigamesframework/TestHelper.java
ChemistsMC/MinigamesFramework
a314d8840af68ff210e72581542cd97c8abc45f4
[ "MIT" ]
null
null
null
src/test/java/com/chemistsmc/minigamesframework/TestHelper.java
ChemistsMC/MinigamesFramework
a314d8840af68ff210e72581542cd97c8abc45f4
[ "MIT" ]
null
null
null
package com.chemistsmc.minigamesframework; import java.io.File; import java.net.URI; import java.net.URISyntaxException; import java.net.URL; import java.nio.file.Path; import java.nio.file.Paths; /** * Test utilities. */ public class TestHelper { public static final String PROJECT_ROOT = "/com/chemistsmc/minigamesframework/"; private TestHelper() { } /** * Return a {@link File} to a file in the JAR's resources (main or test). * * @param path The absolute path to the file * @return The project file */ public static File getJarFile(String path) { URI uri = getUriOrThrow(path); return new File(uri.getPath()); } /** * Return a {@link Path} to a file in the JAR's resources (main or test). * * @param path The absolute path to the file * @return The Path object to the file */ public static Path getJarPath(String path) { String sqlFilePath = getUriOrThrow(path).getPath(); // Windows preprends the path with a '/' or '\', which Paths cannot handle String appropriatePath = System.getProperty("os.name").contains("indow") ? sqlFilePath.substring(1) : sqlFilePath; return Paths.get(appropriatePath); } private static URI getUriOrThrow(String path) { URL url = TestHelper.class.getResource(path); if (url == null) { throw new IllegalStateException("File '" + path + "' could not be loaded"); } try { return new URI(url.toString()); } catch (URISyntaxException e) { throw new IllegalStateException("File '" + path + "' cannot be converted to a URI"); } } }
29.237288
96
0.618551
fbb7bdb3204a52b0d62c9b2bb3a20eced74d7b97
6,065
java
Java
src/java/org/apache/cassandra/streaming/StreamInitiateVerbHandler.java
bstachmann/cassandra
ee8803900b5ad4ffe9b827c64e9cab1d4b8ce499
[ "Apache-2.0" ]
null
null
null
src/java/org/apache/cassandra/streaming/StreamInitiateVerbHandler.java
bstachmann/cassandra
ee8803900b5ad4ffe9b827c64e9cab1d4b8ce499
[ "Apache-2.0" ]
null
null
null
src/java/org/apache/cassandra/streaming/StreamInitiateVerbHandler.java
bstachmann/cassandra
ee8803900b5ad4ffe9b827c64e9cab1d4b8ce499
[ "Apache-2.0" ]
null
null
null
/** * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ package org.apache.cassandra.streaming; import java.io.*; import java.net.InetAddress; import java.util.*; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.apache.cassandra.config.DatabaseDescriptor; import org.apache.cassandra.db.ColumnFamilyStore; import org.apache.cassandra.db.Table; import org.apache.cassandra.io.sstable.SSTable; import org.apache.cassandra.net.IVerbHandler; import org.apache.cassandra.net.Message; import org.apache.cassandra.net.MessagingService; import org.apache.cassandra.streaming.StreamInitiateMessage; import org.apache.cassandra.streaming.StreamInManager; import org.apache.cassandra.service.StorageService; import org.apache.cassandra.utils.FBUtilities; public class StreamInitiateVerbHandler implements IVerbHandler { private static Logger logger = LoggerFactory.getLogger(StreamInitiateVerbHandler.class); /* * Here we handle the StreamInitiateMessage. Here we get the * array of StreamContexts. We get file names for the column * families associated with the files and replace them with the * file names as obtained from the column family store on the * receiving end. */ public void doVerb(Message message) { byte[] body = message.getMessageBody(); ByteArrayInputStream bufIn = new ByteArrayInputStream(body); if (logger.isDebugEnabled()) logger.debug(String.format("StreamInitiateVerbeHandler.doVerb %s %s %s", message.getVerb(), message.getMessageId(), message.getMessageType())); try { StreamInitiateMessage biMsg = StreamInitiateMessage.serializer().deserialize(new DataInputStream(bufIn)); PendingFile[] pendingFiles = biMsg.getStreamContext(); if (pendingFiles.length == 0) { if (logger.isDebugEnabled()) logger.debug("no data needed from " + message.getFrom()); if (StorageService.instance.isBootstrapMode()) StorageService.instance.removeBootstrapSource(message.getFrom(), new String(message.getHeader(StreamOut.TABLE_NAME))); return; } /* * For each of the remote files in the incoming message * generate a local pendingFile and store it in the StreamInManager. */ for (Map.Entry<PendingFile, PendingFile> pendingFile : getContextMapping(pendingFiles).entrySet()) { PendingFile remoteFile = pendingFile.getKey(); PendingFile localFile = pendingFile.getValue(); CompletedFileStatus streamStatus = new CompletedFileStatus(remoteFile.getFilename(), remoteFile.getExpectedBytes()); if (logger.isDebugEnabled()) logger.debug("Preparing to receive stream from " + message.getFrom() + ": " + remoteFile + " -> " + localFile); addStreamContext(message.getFrom(), localFile, streamStatus); } StreamInManager.registerStreamCompletionHandler(message.getFrom(), new StreamCompletionHandler()); if (logger.isDebugEnabled()) logger.debug("Sending a stream initiate done message ..."); Message doneMessage = new Message(FBUtilities.getLocalAddress(), "", StorageService.Verb.STREAM_INITIATE_DONE, new byte[0] ); MessagingService.instance.sendOneWay(doneMessage, message.getFrom()); } catch (IOException ex) { throw new IOError(ex); } } /** * Translates remote files to local files by creating a local sstable * per remote sstable. */ public LinkedHashMap<PendingFile, PendingFile> getContextMapping(PendingFile[] remoteFiles) throws IOException { /* Create a local sstable for each remote sstable */ LinkedHashMap<PendingFile, PendingFile> mapping = new LinkedHashMap<PendingFile, PendingFile>(); Map<SSTable.Descriptor, SSTable.Descriptor> sstables = new HashMap<SSTable.Descriptor, SSTable.Descriptor>(); for (PendingFile remote : remoteFiles) { SSTable.Descriptor remotedesc = remote.getDescriptor(); SSTable.Descriptor localdesc = sstables.get(remotedesc); if (localdesc == null) { // new local sstable Table table = Table.open(remotedesc.ksname); ColumnFamilyStore cfStore = table.getColumnFamilyStore(remotedesc.cfname); localdesc = SSTable.Descriptor.fromFilename(cfStore.getFlushPath()); sstables.put(remotedesc, localdesc); } // add a local file for this component mapping.put(remote, new PendingFile(localdesc, remote.getComponent(), remote.getExpectedBytes())); } return mapping; } private void addStreamContext(InetAddress host, PendingFile pendingFile, CompletedFileStatus streamStatus) { if (logger.isDebugEnabled()) logger.debug("Adding stream context " + pendingFile + " for " + host + " ..."); StreamInManager.addStreamContext(host, pendingFile, streamStatus); } }
43.633094
155
0.670404
05f6d7553ff980a9dc67614676041677b5a399a7
4,955
html
HTML
static/posting.html
ju1115kr/hash-brown
93c5e636404608c7cba889cc9f9e0f3d3d0723b2
[ "Apache-2.0" ]
4
2018-06-27T10:28:54.000Z
2020-03-15T10:44:37.000Z
static/posting.html
ju1115kr/hash-brown
93c5e636404608c7cba889cc9f9e0f3d3d0723b2
[ "Apache-2.0" ]
9
2018-06-27T10:29:37.000Z
2021-12-13T19:48:39.000Z
static/posting.html
ju1115kr/hash-brown
93c5e636404608c7cba889cc9f9e0f3d3d0723b2
[ "Apache-2.0" ]
2
2018-07-04T16:54:20.000Z
2018-07-04T16:58:36.000Z
<!DOCTYPE html> <html> <head> <link rel="stylesheet" type="text/css" href="./posting.css"> <link rel="stylesheet" type="text/css" href="stylesheets/navstyle.css"> </head> <nav> <div id="topMenu"> <div id="navBar"> <div id="logo" style='display:inline;'> <img src="resources/logo.jpg" width="30%" height="30%" margin="30px;"> </div> <div id="searchBar" style='display:inline; margin-left: 70px;'> <input type="text" id="search" placeholder="검색어 입력"> <button type="button" name="searchButton">검색</button> </div> <div id="log" style='display:inline; margin-left: 100px;'> <input class="log" id="id" type="text" placeholder="id"> <input class="log" id="password" type="password" placeholder="password"> <button type="button" name="loginButton" onclick="logIn($('#id').val(),$('#password').val())">로그인</button> </div> </div> <div id="menu"> <a class="menubtn" type="button" name="button" onclick="goToNotice()">공지사항</a> <a class="menubtn" type="button" name="button" onclick="goToPopular()">인기글</a> <a class="menubtn" type="button" name="button" onclick="goToDashboard()">최신글</a> <a class="menubtn" type="button" name="button" onclick="goToRanking()">순위</a> <a class="menubtn" type="button" name="button" onclick="goToWritePage()">글쓰기</a> </div> <body> <div id="main"> <div id="title"> <strong>대표기사/찬성기사/반대기사 글쓰기 <br /> </strong> <hr /> <br /> </div> <form id="subject"> <select id="sub"> <option value="" disabled selected>주제</option> <option value="politics">정치</option> <option value="business">비즈니스</option> <option value="economy">경제</option> <option value="science/technology">과학/기술</option> <option value="entertainment">엔터테인먼트</option> <option value="sports">스포츠</option> <option value="health">건강</option> </select> <div id="mainForm"> <div id="postingTitle"> <input type="text" id="titlebox" placeholder=" 제목" autocomplete="off"> </div> <div id="subForm"> <div id="functionForm"> &nbsp; <select id="font"> <option value="arial" font-family="arial" abled selected>Arial</option> <option value="timesnewroman" font-family="timesnewroman" abled selected>Times New Roman</option> <option value="courier" font-family="courier" abled selected>Courier</option> <option value="georgia" font-family="georgia" abled selected>Georgia</option> </select> &nbsp;&nbsp; <input type="number" id="fontsizebox" value="10.0" min="1.0" max="500.0" > &nbsp;<p id="pivotline">|</p>&nbsp; <a id="bold", title="진하게"> <b>가</b> </a> <a id="italic", title="기울임"> <i>가</i> </a> <a id="underline", title="밑줄선"> <u>가</u> </a> <a id="deline", title="취소선"> <del>가</del> </a> <a id="color", title="글자 색"> <img src="./posting icon/color.png" width="20px", height="20px"> </a> <a id="highlight", title="하이라이트"> <img src="./posting icon/highlight.png" width="20px", height="20px"> </a> &nbsp;<p id="pivotline">|</p>&nbsp; <a id="left"> <img src="./posting icon/left.png" width="20px", height="20px", title="왼쪽 정렬"> </a> <a id="center"> <img src="./posting icon/center.png" width="20px", height="20px", title="가운데 정렬"> </a> <a id="right"> <img src="./posting icon/right.png" width="20px", height="20px", title="오른쪽 정렬"> </a> &nbsp;<p id="pivotline">|</p>&nbsp; <a id="picture"> <img src="./posting icon/picture.png" width="20px", height="20px", title="사진 첨부"> </a> <a id="video"> <img src="./posting icon/video.png" width="20px", height="20px", title="동영상 첨부"> </a> &nbsp;<p id="pivotline">|</p>&nbsp; <a id="link"> <img src="./posting icon/link.png" width="20px", height="20px", title="링크"> </a> <a id="quote"> <img src="./posting icon/quote.png" width="20px", height="20px", title="인용"> </a> &nbsp;<p id="pivotline">|</p>&nbsp; <a id="search"> <img src="./posting icon/search.png" width="20px", height="20px", title="검색"> </a> <input id="searching" type="text" value="검 색"> <!-- <button type="button"><b>가</b></button> <button type="button"><i>가</i></button> <button type="button"><u>가</u></button> <button type="button"><del>가</del></button> --> </div> <textarea id="postBox" placeholder=" 여기를 눌러 기사를 작성해보세요." autocomplete="off"></textarea> </div> <div id="postSendBar"> <input id="postTempStore" type="submit" value="임시저장"> <input id="postSubmit" type="submit" value="확인"> </div> </div> </form> </body> </html>
37.255639
110
0.556811
05bab26f4c3139fac23f27600c6c9d5491f5bcde
9,563
html
HTML
index.html
ged-dev/cryptexe_final
e123156236402ef24edf2b32df12833d605cafbc
[ "MIT" ]
null
null
null
index.html
ged-dev/cryptexe_final
e123156236402ef24edf2b32df12833d605cafbc
[ "MIT" ]
null
null
null
index.html
ged-dev/cryptexe_final
e123156236402ef24edf2b32df12833d605cafbc
[ "MIT" ]
null
null
null
<!DOCTYPE html> <html lang="fr"> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="description" content=""> <meta name="author" content=""> <title>Cryptexe</title> <link rel="icon" type="image/png" href="img/favicon.png" /> <!-- Bootstrap Core CSS --> <link href="vendor/bootstrap/css/bootstrap.css" rel="stylesheet"> <!-- Custom Fonts --> <link href="vendor/font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css"> <link href="https://fonts.googleapis.com/css?family=Lora:400,700,400italic,700italic" rel="stylesheet" type="text/css"> <link href="https://fonts.googleapis.com/css?family=Montserrat:400,700" rel="stylesheet" type="text/css"> <!-- Theme CSS --> <link href="css/grayscale.min.css" rel="stylesheet"> <link href="css/grayscale_style.css" rel="stylesheet"> <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries --> <!-- WARNING: Respond.js doesn't work if you view the page via file:// --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script> <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script> <![endif]--> </head> <body id="page-top" data-spy="scroll" data-target=".navbar-fixed-top"> <!-- Navigation --> <nav class="navbar navbar-custom navbar-fixed-top" role="navigation"> <div class="container"> <div class="navbar-header"> <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-main-collapse"> Menu <i class="fa fa-bars"></i> </button> <a class="navbar-brand page-scroll" href="#page-top"> <img src="img/logo.png" alt=""> </a> </div> <!-- Collect the nav links, forms, and other content for toggling --> <div class="collapse navbar-collapse navbar-right navbar-main-collapse"> <ul class="nav navbar-nav"> <!-- Hidden li included to remove active class from about link when scrolled up past about section --> <li class="hidden"> <a href="#page-top"></a> </li> <li class="top-menu-items"> <a class="page-scroll" href="#about">Vocabulaire</a> </li> <li class="top-menu-items"> <a class="page-scroll" href="#download">Histoire</a> </li> <li class="top-menu-items"> <a class="page-scroll" href="#contact">Législation</a> </li> <li class="top-menu-items crypt"> <a href="cryptage.html">Cryptages</a> </li> </ul> </div> <!-- /.navbar-collapse --> </div> <!-- /.container --> </nav> <!-- Intro Header --> <header class="intro"> <div class="intro-body"> <div class="container"> <div class="row"> <div class="col-md-8 col-md-offset-2"> <h1 class="brand-heading">Cryptexe</h1> <p class="intro-text">Un site responsive pour en apprendre plus sur le cyptage.</p> <a href="#about" class="btn btn-circle page-scroll"> <i class="fa fa-angle-double-down animated"></i> </a> </div> </div> </div> </div> </header> <!-- About Section --> <section id="about" class="container content-section text-center"> <div class="container"> <div class="blank-items"></div> <div class="row"> <div class="col-lg-12"> <h2>Vocabulaire</h2> <table> <tr> <td class="text_data_left"><p><b>Chiffrer</b></p></td> <td class="text_data_right"><p>Utilisation de la substitution au niveau des lettres pour coder.</p></td> </tr> <tr> <td class="text_data_left"><p><b>Code</b></p></td> <td class="text_data_right"><p>Utilisation de la substitution au niveau des mots pour coder</p></td> </tr> <tr> <td class="text_data_left"><p><b>Déchiffrer</b></p></td> <td class="text_data_right"><p>Utiliser la clé de chiffrement pour retrouver le message codé</p></td> </tr> <tr> <td class="text_data_left"><p><b>Crypter</b></p></td> <td class="text_data_right"><p>N'existe pas, on ne peut pas chiffrer un message sans en connaitre la clé, ca n'a pas de sens.</p></td> </tr> <tr> <td class="text_data_left"><p><b>Décrypter</b></p></td> <td class="text_data_right"><p>Retrouver le message clair correspondant à un message chiffré sans en posséder la clé de déchiffrement.</p></td> </tr> <tr> <td class="text_data_left"><p><b>Cryptologie</b></p></td> <td class="text_data_right"><p>La science du secret, reconnue depuis peu, englobant cryptographie, cryptanalyse.</p></td> </tr> <tr> <td class="text_data_left"><p><b>Cryptographie</b></p></td> <td class="text_data_right"><p>L'art du secret, rendre un message inintelligible à autre que qui-de-droit.</p></td> </tr> <tr> <td class="text_data_left"><p><b>Sténographie</b></p></td> <td class="text_data_right"><p>L'art de la dissimulation, faire passer un message inapercu dans un autre message.</p></td> </tr> </table> </div> </div> </div> </section> <!-- Download Section --> <section class="content-section text-center"> <div class="download-section" id="download"> <div class="container"> <div class="col-lg-12"> <h2>Histoire</h2> <p>Le principe de chiffrement ou cryptage ( du grec: caché,secret ) caracterise le procédé de cryptographie par lequel on rend la compréhension d'un document impossible à toute personne qui ne possède pas la clé de déchiffrement.</p> <p>La méthode existe depuis des siècles déja, par exemple Jules César a donné son nom à une méthode de chiffrement par décalage, les templiers eux aussi utilisaient les rosaces des 8 béattitudes pour coder leur alphabet.</p> <p>Il aura néanmoins fallut attendre les années 1600 pour que le terme chiffrement soit utilisé.</p> <p>Au fur et a mesure que les moyens mis en place et la technologie le permettaient, les moyens de chiffrement ont évolué, avec l'arrivée de signatures numériques, de clés de cryptage, de bruit (transmission codée sur un canal, ex: signaux télévisés nécessitants un décodeur pour obtenir la chaine).</p> </div> </div> </div> </section> <!-- Contact Section --> <section id="contact" class="container content-section text-center"> <div class="row"> <div class="col-lg-12"> <h2>Législation</h2> <p>Longtemps utilisés pendant la guerre, les machines et logiciels de chiffrement ont étés bannis en France jusqu'en 1996 car considérés comme une arme de guerre de deuxieme catégorie.</p> <p>La législation s'étant assouplie, le chiffrement symétrique avec des clés jusqu'a 128 bits furent autorisés.</p> <p>Enfin, la loi pour la confiance dans l'économie numérique, en 2014, libère totalement l'usage des moyens de cryptologie, par contre l'importation ou l'exportation sont toujours soumises à autorisation.</p> </div> </div> </section> <!-- Footer --> <footer> <div class="container text-center"> <p class="copy_text">Copyright &copy; Cryptexe 2017</p> </div> </footer> <!-- jQuery --> <script src="vendor/jquery/jquery.js"></script> <!-- Bootstrap Core JavaScript --> <script src="vendor/bootstrap/js/bootstrap.min.js"></script> <!-- Plugin JavaScript --> <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-easing/1.3/jquery.easing.min.js"></script> <!-- Google Maps API Key - Use your own API key to enable the map feature. More information on the Google Maps API can be found at https://developers.google.com/maps/ --> <script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?key=AIzaSyCRngKslUGJTlibkQ3FkfTxj3Xss1UlZDA&sensor=false"></script> <!-- Theme JavaScript --> <script src="js/grayscale.js"></script> </body> </html>
46.64878
174
0.537802
2f31b3beff0b48b6ef0b1f4a195206fb49be5b5b
7,348
java
Java
editor/src/main/java/struct/StructOutput.java
ykrkn/korg-es2
f374ef47c6d2a8cbafe0232aa126cb68720f4169
[ "Apache-2.0" ]
null
null
null
editor/src/main/java/struct/StructOutput.java
ykrkn/korg-es2
f374ef47c6d2a8cbafe0232aa126cb68720f4169
[ "Apache-2.0" ]
6
2021-03-09T01:59:10.000Z
2022-02-26T10:13:12.000Z
editor/src/main/java/struct/StructOutput.java
ykrkn/korg-es2
f374ef47c6d2a8cbafe0232aa126cb68720f4169
[ "Apache-2.0" ]
null
null
null
package struct; import java.io.IOException; import java.io.OutputStream; import java.lang.reflect.Field; import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; public abstract class StructOutput extends OutputStream { @Override public void write(int arg0) throws IOException { } public void writeObject(Object obj) throws StructException{ if(obj == null) throw new StructException("Struct classes cant be null. "); StructData info = StructUtils.getStructInfo(obj); boolean lengthedArray = false; int arrayLength = 0; for (Field currentField : info.getFields()) { //System.out.println("Processing field: " + currentField.getName()); StructFieldData fieldData = info.getFieldData(currentField.getName()); if(fieldData == null) { throw new StructException("Field Data not found for field: " + currentField.getName()); } lengthedArray = false; arrayLength = 0; try{ if(fieldData.isArrayLengthMarker()){ if (fieldData.requiresGetterSetter()) { arrayLength = ((Number)fieldData.getGetter().invoke( obj, (Object[])null)).intValue(); } else { arrayLength = ((Number)fieldData.getField().get(obj)).intValue(); } lengthedArray = true; } if ( fieldData.requiresGetterSetter()){ if(lengthedArray && arrayLength >= 0){ writeField(fieldData, fieldData.getGetter(), obj, arrayLength); } else writeField(fieldData, fieldData.getGetter(), obj, -1); } // Field is public. Access directly. else { if(lengthedArray && arrayLength >= 0){ writeField(fieldData, null, obj, arrayLength); } // Array is null if Length is negative. else { writeField(fieldData, null, obj, -1); } } } catch (Exception e) { throw new StructException(e); } } } /** * Write a fields value. Field can be an primitive, array or another object. */ public void writeField( StructFieldData fieldData, Method getter, Object obj, int len ) throws IllegalAccessException, IOException, InvocationTargetException, StructException { Field field = fieldData.getField(); if ( !field.getType().isArray() ) { switch(fieldData.getType()) { case BOOLEAN: if(getter != null) writeBoolean((Boolean)getter.invoke(obj, (Object[])null)); else writeBoolean(field.getBoolean(obj)); break; case BYTE: if(getter != null) writeByte((Byte)getter.invoke(obj, (Object[])null)); else writeByte(field.getByte(obj)); break; case SHORT: if(getter != null) writeShort((Short)getter.invoke(obj, (Object[])null)); else writeShort(field.getShort(obj)); break; case INT: if(getter != null) writeInt((Integer)getter.invoke(obj, (Object[])null)); else writeInt(field.getInt(obj)); break; case LONG: long longValue; if(getter != null) longValue = (Long)getter.invoke(obj, (Object[])null); else longValue = field.getLong(obj); writeLong(longValue); break; case CHAR: if(getter != null) writeChar((Character)getter.invoke(obj, (Object[])null)); else writeChar(field.getChar(obj)); break; case FLOAT: if(getter != null) writeFloat((Float)getter.invoke(obj, (Object[])null)); else writeFloat(field.getFloat(obj)); break; case DOUBLE: if(getter != null) writeDouble((Double)getter.invoke(obj, (Object[])null)); else writeDouble(field.getDouble(obj)); break; // Object default : if(getter != null) handleObject(field, getter.invoke(obj, (Object[])null)); else handleObject(field, obj); break; } } else { switch(fieldData.getType()) { case BOOLEAN: if(getter != null) writeBooleanArray((boolean[])getter.invoke(obj, (Object[])null), len); else writeBooleanArray((boolean[]) field.get(obj), len); break; case BYTE: if(getter != null) writeByteArray((byte[])getter.invoke(obj, (Object[])null), len); else writeByteArray((byte[]) field.get(obj), len); break; case CHAR: if(getter != null) writeCharArray((char[])getter.invoke(obj, (Object[])null), len); else writeCharArray((char[]) field.get(obj), len); break; case SHORT: if(getter != null) writeShortArray((short[])getter.invoke(obj, (Object[])null), len); else writeShortArray((short[]) field.get(obj), len); break; case INT: if(getter != null) writeIntArray((int[])getter.invoke(obj, (Object[])null), len); else writeIntArray((int[]) field.get(obj), len); break; case LONG: if(getter != null) writeLongArray((long[])getter.invoke(obj, (Object[])null), len); else writeLongArray((long[]) field.get(obj), len); break; case FLOAT: if(getter != null) writeFloatArray((float[])getter.invoke(obj, (Object[])null), len); else writeFloatArray((float[]) field.get(obj), len); break; case DOUBLE: if(getter != null) writeDoubleArray((double[])getter.invoke(obj, (Object[])null), len); else writeDoubleArray((double[]) field.get(obj), len); break; default: if(getter != null) writeObjectArray((Object[])getter.invoke(obj, (Object[])null), len); else writeObjectArray((Object[]) field.get(obj), len); break; } } } public void handleObject(Field field, Object obj) throws IllegalArgumentException, StructException, IllegalAccessException, IOException { writeObject(field.get(obj)); } public abstract void writeBoolean(boolean value) throws IOException; public abstract void writeByte(byte value) throws IOException ; public abstract void writeShort(short value) throws IOException; public abstract void writeInt(int value) throws IOException; public abstract void writeLong(long value) throws IOException ; public abstract void writeChar(char value) throws IOException ; public abstract void writeFloat(float value) throws IOException; public abstract void writeDouble(double value) throws IOException; public abstract void writeBooleanArray(boolean buffer[], int len) throws IOException; public abstract void writeByteArray(byte buffer[], int len) throws IOException ; public abstract void writeCharArray(char buffer[], int len) throws IOException; public abstract void writeShortArray(short buffer[], int len) throws IOException; public abstract void writeIntArray(int buffer[], int len) throws IOException; public abstract void writeLongArray(long buffer[], int len) throws IOException; public abstract void writeFloatArray(float buffer[], int len) throws IOException; public abstract void writeDoubleArray(double buffer[], int len) throws IOException ; public abstract void writeObjectArray(Object buffer[], int len) throws IOException, IllegalAccessException, InvocationTargetException, StructException; }
35.157895
110
0.636636
f9c3e51746ce576fa983343ab4cdee02d48503d7
2,617
sql
SQL
database-export/Dump20191025/TrackWorkSpace_sensor_status.sql
wiprodevnet/iot-workspace-management
36491651c7fb254bc29c193b6daae09bb6805956
[ "MIT" ]
null
null
null
database-export/Dump20191025/TrackWorkSpace_sensor_status.sql
wiprodevnet/iot-workspace-management
36491651c7fb254bc29c193b6daae09bb6805956
[ "MIT" ]
null
null
null
database-export/Dump20191025/TrackWorkSpace_sensor_status.sql
wiprodevnet/iot-workspace-management
36491651c7fb254bc29c193b6daae09bb6805956
[ "MIT" ]
1
2019-10-25T10:37:34.000Z
2019-10-25T10:37:34.000Z
-- MySQL dump 10.13 Distrib 5.7.27, for Linux (x86_64) -- -- Host: localhost Database: TrackWorkSpace -- ------------------------------------------------------ -- Server version 5.7.27-0ubuntu0.18.04.1 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8 */; /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; /*!40103 SET TIME_ZONE='+00:00' */; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; -- -- Table structure for table `sensor_status` -- DROP TABLE IF EXISTS `sensor_status`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `sensor_status` ( `sensor_status_idn` int(11) NOT NULL AUTO_INCREMENT, `sensor_serial_no` varchar(45) NOT NULL, `sensor_status` varchar(45) NOT NULL, `sensor_idn` int(11) DEFAULT NULL, `crt_dt` datetime DEFAULT NULL, `upd_dt` datetime DEFAULT NULL, PRIMARY KEY (`sensor_status_idn`), UNIQUE KEY `sensor_serial_no_UNIQUE` (`sensor_serial_no`), KEY `fk_sensor_status_1_idx` (`sensor_idn`) ) ENGINE=InnoDB AUTO_INCREMENT=4188 DEFAULT CHARSET=latin1; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `sensor_status` -- LOCK TABLES `sensor_status` WRITE; /*!40000 ALTER TABLE `sensor_status` DISABLE KEYS */; INSERT INTO `sensor_status` VALUES (4183,'PS100-10001','OFF',1,'2019-10-22 11:17:55','2019-10-24 18:35:15'),(4184,'PS100-10002','OFF',10,'2019-10-22 11:17:55','2019-10-24 18:35:15'),(4185,'PS100-10003','OFF',11,'2019-10-22 11:17:55','2019-10-24 18:35:15'),(4186,'PS100-10004','OFF',12,'2019-10-22 11:17:55','2019-10-24 18:35:15'),(4187,'PS100-10005','ON',13,'2019-10-22 11:17:55','2019-10-24 18:35:15'); /*!40000 ALTER TABLE `sensor_status` ENABLE KEYS */; UNLOCK TABLES; /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; /*!40101 SET SQL_MODE=@OLD_SQL_MODE */; /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */; /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; -- Dump completed on 2019-10-25 15:54:35
45.12069
403
0.712266
78a392c8a055a4d6e37546af8de053daa8ca9f27
3,679
swift
Swift
CommitBrowserTests/Mocks/MockNetworkService.swift
dhomes/CommitBrowser
7e44c12657de9076600ae7a7a627d91d5e06d839
[ "MIT" ]
null
null
null
CommitBrowserTests/Mocks/MockNetworkService.swift
dhomes/CommitBrowser
7e44c12657de9076600ae7a7a627d91d5e06d839
[ "MIT" ]
null
null
null
CommitBrowserTests/Mocks/MockNetworkService.swift
dhomes/CommitBrowser
7e44c12657de9076600ae7a7a627d91d5e06d839
[ "MIT" ]
null
null
null
// // MockNetworkService.swift // CommitBrowserTests // // Created by dhomes on 11/8/20. // import Foundation @testable import CommitBrowser class MockNetworkService : NetworkService { func getFiles(for commit: Commit, completion: ((Result<[File], Error>) -> ())?) { guard let url = Bundle.init(for: type(of: self)).url(forResource: "Files", withExtension: "json") else { completion?(.failure(NetworkError.other(message: "Could not parse Files json file"))) return } do { let data = try Data(contentsOf: url) let json = try JSON(data: data) let files = json.arrayValue.compactMap { GitHubFile(json: $0) } completion?(.success(files)) } catch { completion?(.failure(error)) } } func getCommits(with request: APIRequest, completion: ((Result<[Commit], Error>) -> ())?) { guard let url = Bundle.init(for: type(of: self)).url(forResource: "CurrentCommits", withExtension: "json") else { completion?(.failure(NetworkError.other(message: "Could not parse Commits json file"))) return } do { let data = try Data(contentsOf: url) let json = try JSON(data: data) let commits = json.arrayValue.compactMap { GitHubCommit(json: $0) } guard commits.count > 0 else { completion?(.failure(NetworkError.other(message: "Commit parsing failed"))) return } let params = request.queryParameters let size = params["per_page"] as? Int let until = params["until"] as? String var belowDate : Date? = nil let formatter = ISO8601DateFormatter() if let until = until { belowDate = formatter.date(from: until) } if belowDate == nil { if size == nil { completion?(.success(commits)) } else { let headcommits = Array(commits[0..<size!]) completion?(.success(headcommits)) } } else { let below = belowDate! if size == nil { if let first = commits.firstIndex(where: { $0.date < below }) { let nextcommits = Array(commits[first..<commits.count]) completion?(.success(nextcommits)) } else { // we are at a date before any available completion?(.success([Commit]())) } } else { // we have a date and a page size let page = size! if let first = commits.firstIndex(where: { $0.date < below }) { if (first + page) < commits.count { let commits = Array(commits[first..<first+page]) completion?(.success(commits)) } else { let commits = Array(commits[first..<commits.count]) completion?(.success(commits)) } } else { // we are at a date before any available completion?(.success([Commit]())) } } } } catch { completion?(.failure(error)) } } }
37.161616
121
0.463169
3d02fa8c45d6613adb8b44be165f488b1203fce9
4,523
go
Go
main.go
mlowicki/termtodo
b2112c4c1efe392dbd615e880b5ef498f3b7f614
[ "MIT" ]
1
2020-12-17T10:48:22.000Z
2020-12-17T10:48:22.000Z
main.go
mlowicki/termtodo
b2112c4c1efe392dbd615e880b5ef498f3b7f614
[ "MIT" ]
null
null
null
main.go
mlowicki/termtodo
b2112c4c1efe392dbd615e880b5ef498f3b7f614
[ "MIT" ]
null
null
null
package main import ( "flag" "fmt" "log" "os" "os/signal" "syscall" "time" "github.com/google/uuid" "github.com/nsf/termbox-go" cron "github.com/robfig/cron/v3" ) // Todo represents something to accomplish. type Todo struct { Name string ID string CreatedAt time.Time } // Trigger defines when to create a Todo. type Trigger struct { Name string Cron string After time.Time Count int ID string } func NewTrigger(name, cron string, after time.Time, count int) (Trigger, error) { t := Trigger{ Name: name, Cron: cron, After: after, Count: count, ID: uuid.New().String(), } _, err := t.Schedule() // validate schedule return t, err } func (t *Trigger) Schedule() (cron.Schedule, error) { parser := cron.NewParser(cron.SecondOptional | cron.Minute | cron.Hour | cron.Dom | cron.Month | cron.Dow | cron.Descriptor) sched, err := parser.Parse(t.Cron) if err != nil { return nil, fmt.Errorf("invalid schedule: %w", err) } return sched, nil } func (t *Trigger) Next() time.Time { if t.Count == 0 { return time.Time{} } sch, err := t.Schedule() if err != nil { panic(err) } return sch.Next(t.After) } func (t *Trigger) Check() *Todo { now := time.Now() if t.Count == 0 || t.Next().After(now) { return nil } t.After = now if t.Count != -1 { t.Count-- } return &Todo{Name: t.Name, ID: uuid.New().String(), CreatedAt: time.Now()} } type Scheduler struct { TodosCh chan []Todo TriggersCh chan []Trigger AddTriggersCh chan []Trigger DelTriggersCh chan []string DelTodosCh chan []string timer *time.Timer db *DB } func (sch *Scheduler) checkTriggers() { triggers := make(map[string]Trigger) for _, trigger := range sch.db.Triggers { if todo := trigger.Check(); todo != nil { sch.db.Todos[(*todo).ID] = *todo } if !trigger.Next().IsZero() { triggers[trigger.ID] = trigger } } sch.db.Triggers = triggers err := sch.db.Write() if err != nil { panic(err) } } func (sch *Scheduler) sendTodos() { todos := make([]Todo, 0, len(sch.db.Todos)) for _, todo := range sch.db.Todos { todos = append(todos, todo) } sch.TodosCh <- todos } func (sch *Scheduler) sendTriggers() { triggers := make([]Trigger, 0, len(sch.db.Triggers)) for _, trigger := range sch.db.Triggers { triggers = append(triggers, trigger) } sch.TriggersCh <- triggers } func NewScheduler(db *DB) *Scheduler { sch := Scheduler{ TodosCh: make(chan []Todo), TriggersCh: make(chan []Trigger), AddTriggersCh: make(chan []Trigger), DelTriggersCh: make(chan []string), DelTodosCh: make(chan []string), timer: time.NewTimer(time.Millisecond), db: db, } go func() { sch.sendTodos() sch.sendTriggers() for { timerExpired := false triggersNum := len(db.Triggers) todosNum := len(db.Todos) select { case ids := <-sch.DelTodosCh: for _, id := range ids { delete(db.Todos, id) } err := sch.db.Write() if err != nil { panic(err) } case triggers := <-sch.AddTriggersCh: for _, trigger := range triggers { db.Triggers[trigger.ID] = trigger } sch.checkTriggers() case ids := <-sch.DelTriggersCh: for _, id := range ids { delete(db.Triggers, id) } err := sch.db.Write() if err != nil { panic(err) } case <-sch.timer.C: sch.checkTriggers() timerExpired = true } if len(db.Todos) != todosNum { sch.sendTodos() } if len(db.Triggers) != triggersNum { sch.sendTriggers() } nextCheck := time.Now().Add(time.Hour * 24 * 7) for _, trigger := range sch.db.Triggers { n := trigger.Next() if !n.IsZero() && n.Before(nextCheck) { nextCheck = n } } if !timerExpired && !sch.timer.Stop() { <-sch.timer.C } sch.timer.Reset(time.Until(nextCheck)) } }() return &sch } func main() { var dbpath = flag.String("dbpath", ".termtodo.db", "path to database") flag.Parse() db, err := NewDB(*dbpath) if err != nil { log.Fatalf("Cannot initialize database: %s", err) } scheduler := NewScheduler(db) ui := NewUI(scheduler) defer ui.Close() go func() { contCh := make(chan os.Signal, 1) signal.Notify(contCh, syscall.SIGCONT) termCh := make(chan os.Signal, 1) signal.Notify(termCh, syscall.SIGTERM) for { select { case <-contCh: ui.Close() err = termbox.Init() if err != nil { panic(err) } ui.Redraw() case <-termCh: ui.Close() os.Exit(0) } } }() ui.Run() }
20.559091
125
0.609772
944f31e1fa1ca1af0b21857acc8c195231f2c35d
1,010
lua
Lua
projects/hanappe-samples/src/samples/gui/messagebox_sample.lua
theGoodEvil/Hanappe
0488bc360be91a8d34e3651f2c61c143b412d4f7
[ "Apache-2.0" ]
null
null
null
projects/hanappe-samples/src/samples/gui/messagebox_sample.lua
theGoodEvil/Hanappe
0488bc360be91a8d34e3651f2c61c143b412d4f7
[ "Apache-2.0" ]
null
null
null
projects/hanappe-samples/src/samples/gui/messagebox_sample.lua
theGoodEvil/Hanappe
0488bc360be91a8d34e3651f2c61c143b412d4f7
[ "Apache-2.0" ]
null
null
null
module(..., package.seeall) function onCreate(params) view = View { scene = scene, layout = VBoxLayout { align = {"center", "center"}, padding = {10, 10, 10, 10}, }, } showButton = Button { text = "Show", size = {200, 50}, parent = view, onClick = onShowClick, } hideButton = Button { text = "Hide", size = {200, 50}, parent = view, onClick = onHideClick, } backButton = Button { text = "Back", size = {200, 50}, parent = view, onClick = onBackClick, } messageBox = MessageBox { size = {view:getWidth() - 20, 120}, text = "メッセージボックスのさんぷるです。\n内部的にはTextLabelが表示されています。\nHello MessageBox!\n改行とか?", parent = view, } end function onShowClick(e) messageBox:show() end function onHideClick(e) messageBox:hide() end function onBackClick(e) SceneManager:closeScene({animation = "fade"}) end
21.489362
87
0.535644
74b69235c8976dc082cf2898ebda2f43295f9dc1
566
js
JavaScript
tests/controllers/register.test.js
Jaak03/Global-Train-API
6f3ec0e8ae67b80b21ab30dcd3958ab3cdad3f7b
[ "MIT" ]
null
null
null
tests/controllers/register.test.js
Jaak03/Global-Train-API
6f3ec0e8ae67b80b21ab30dcd3958ab3cdad3f7b
[ "MIT" ]
1
2021-05-11T13:47:02.000Z
2021-05-11T13:47:02.000Z
tests/controllers/register.test.js
Jaak03/Global-Train-API
6f3ec0e8ae67b80b21ab30dcd3958ab3cdad3f7b
[ "MIT" ]
null
null
null
const { expect } = require('chai'); const { controllers: { register } } = require('../env'); const { userToRegister } = require('./args'); describe('user', () => { describe('register', () => { let response; before(async function() { this.timeout(5000); response = await register(userToRegister); }); it('response should be ok', () => { expect(response).to.be.ok; }); it('should return insert user to database', () => { console.log(response); expect(response).to.have.property('upsert'); }); }); });
22.64
56
0.565371
dd92ac440589c135eb00fba2115250ba17a492cf
7,009
asm
Assembly
scripts/Route17.asm
AmateurPanda92/pokemon-rby-dx
f7ba1cc50b22d93ed176571e074a52d73360da93
[ "MIT" ]
9
2020-07-12T19:44:21.000Z
2022-03-03T23:32:40.000Z
scripts/Route17.asm
JStar-debug2020/pokemon-rby-dx
c2fdd8145d96683addbd8d9075f946a68d1527a1
[ "MIT" ]
7
2020-07-16T10:48:52.000Z
2021-01-28T18:32:02.000Z
scripts/Route17.asm
JStar-debug2020/pokemon-rby-dx
c2fdd8145d96683addbd8d9075f946a68d1527a1
[ "MIT" ]
2
2021-03-28T18:33:43.000Z
2021-05-06T13:12:09.000Z
Route17_Script: call EnableAutoTextBoxDrawing ld hl, Route17TrainerHeader0 ld de, Route17_ScriptPointers ld a, [wRoute17CurScript] call ExecuteCurMapScriptInTable ld [wRoute17CurScript], a ret Route17_ScriptPointers: dw CheckFightingMapTrainers dw DisplayEnemyTrainerTextAndStartBattle dw EndTrainerBattle Route17_TextPointers: dw Route17Text1 dw Route17Text2 dw Route17Text3 dw Route17Text4 dw Route17Text5 dw Route17Text6 dw Route17Text7 dw Route17Text8 dw Route17Text9 dw Route17Text10 dw Route17Text11 dw Route17Text12 dw Route17Text13 dw Route17Text14 dw Route17Text15 dw Route17Text16 Route17TrainerHeader0: dbEventFlagBit EVENT_BEAT_ROUTE_17_TRAINER_0 db ($3 << 4) ; trainer's view range dwEventFlagAddress EVENT_BEAT_ROUTE_17_TRAINER_0 dw Route17BattleText1 ; TextBeforeBattle dw Route17AfterBattleText1 ; TextAfterBattle dw Route17EndBattleText1 ; TextEndBattle dw Route17EndBattleText1 ; TextEndBattle Route17TrainerHeader1: dbEventFlagBit EVENT_BEAT_ROUTE_17_TRAINER_1 db ($4 << 4) ; trainer's view range dwEventFlagAddress EVENT_BEAT_ROUTE_17_TRAINER_1 dw Route17BattleText2 ; TextBeforeBattle dw Route17AfterBattleText2 ; TextAfterBattle dw Route17EndBattleText2 ; TextEndBattle dw Route17EndBattleText2 ; TextEndBattle Route17TrainerHeader2: dbEventFlagBit EVENT_BEAT_ROUTE_17_TRAINER_2 db ($4 << 4) ; trainer's view range dwEventFlagAddress EVENT_BEAT_ROUTE_17_TRAINER_2 dw Route17BattleText3 ; TextBeforeBattle dw Route17AfterBattleText3 ; TextAfterBattle dw Route17EndBattleText3 ; TextEndBattle dw Route17EndBattleText3 ; TextEndBattle Route17TrainerHeader3: dbEventFlagBit EVENT_BEAT_ROUTE_17_TRAINER_3 db ($4 << 4) ; trainer's view range dwEventFlagAddress EVENT_BEAT_ROUTE_17_TRAINER_3 dw Route17BattleText4 ; TextBeforeBattle dw Route17AfterBattleText4 ; TextAfterBattle dw Route17EndBattleText4 ; TextEndBattle dw Route17EndBattleText4 ; TextEndBattle Route17TrainerHeader4: dbEventFlagBit EVENT_BEAT_ROUTE_17_TRAINER_4 db ($3 << 4) ; trainer's view range dwEventFlagAddress EVENT_BEAT_ROUTE_17_TRAINER_4 dw Route17BattleText5 ; TextBeforeBattle dw Route17AfterBattleText5 ; TextAfterBattle dw Route17EndBattleText5 ; TextEndBattle dw Route17EndBattleText5 ; TextEndBattle Route17TrainerHeader5: dbEventFlagBit EVENT_BEAT_ROUTE_17_TRAINER_5 db ($2 << 4) ; trainer's view range dwEventFlagAddress EVENT_BEAT_ROUTE_17_TRAINER_5 dw Route17BattleText6 ; TextBeforeBattle dw Route17AfterBattleText6 ; TextAfterBattle dw Route17EndBattleText6 ; TextEndBattle dw Route17EndBattleText6 ; TextEndBattle Route17TrainerHeader6: dbEventFlagBit EVENT_BEAT_ROUTE_17_TRAINER_6 db ($4 << 4) ; trainer's view range dwEventFlagAddress EVENT_BEAT_ROUTE_17_TRAINER_6 dw Route17BattleText7 ; TextBeforeBattle dw Route17AfterBattleText7 ; TextAfterBattle dw Route17EndBattleText7 ; TextEndBattle dw Route17EndBattleText7 ; TextEndBattle Route17TrainerHeader7: dbEventFlagBit EVENT_BEAT_ROUTE_17_TRAINER_7, 1 db ($2 << 4) ; trainer's view range dwEventFlagAddress EVENT_BEAT_ROUTE_17_TRAINER_7, 1 dw Route17BattleText8 ; TextBeforeBattle dw Route17AfterBattleText8 ; TextAfterBattle dw Route17EndBattleText8 ; TextEndBattle dw Route17EndBattleText8 ; TextEndBattle Route17TrainerHeader8: dbEventFlagBit EVENT_BEAT_ROUTE_17_TRAINER_8, 1 db ($3 << 4) ; trainer's view range dwEventFlagAddress EVENT_BEAT_ROUTE_17_TRAINER_8, 1 dw Route17BattleText9 ; TextBeforeBattle dw Route17AfterBattleText9 ; TextAfterBattle dw Route17EndBattleText9 ; TextEndBattle dw Route17EndBattleText9 ; TextEndBattle Route17TrainerHeader9: dbEventFlagBit EVENT_BEAT_ROUTE_17_TRAINER_9, 1 db ($4 << 4) ; trainer's view range dwEventFlagAddress EVENT_BEAT_ROUTE_17_TRAINER_9, 1 dw Route17BattleText10 ; TextBeforeBattle dw Route17AfterBattleText10 ; TextAfterBattle dw Route17EndBattleText10 ; TextEndBattle dw Route17EndBattleText10 ; TextEndBattle db $ff Route17Text1: TX_ASM ld hl, Route17TrainerHeader0 call TalkToTrainer jp TextScriptEnd Route17BattleText1: TX_FAR _Route17BattleText1 db "@" Route17EndBattleText1: TX_FAR _Route17EndBattleText1 db "@" Route17AfterBattleText1: TX_FAR _Route17AfterBattleText1 db "@" Route17Text2: TX_ASM ld hl, Route17TrainerHeader1 call TalkToTrainer jp TextScriptEnd Route17BattleText2: TX_FAR _Route17BattleText2 db "@" Route17EndBattleText2: TX_FAR _Route17EndBattleText2 db "@" Route17AfterBattleText2: TX_FAR _Route17AfterBattleText2 db "@" Route17Text3: TX_ASM ld hl, Route17TrainerHeader2 call TalkToTrainer jp TextScriptEnd Route17BattleText3: TX_FAR _Route17BattleText3 db "@" Route17EndBattleText3: TX_FAR _Route17EndBattleText3 db "@" Route17AfterBattleText3: TX_FAR _Route17AfterBattleText3 db "@" Route17Text4: TX_ASM ld hl, Route17TrainerHeader3 call TalkToTrainer jp TextScriptEnd Route17BattleText4: TX_FAR _Route17BattleText4 db "@" Route17EndBattleText4: TX_FAR _Route17EndBattleText4 db "@" Route17AfterBattleText4: TX_FAR _Route17AfterBattleText4 db "@" Route17Text5: TX_ASM ld hl, Route17TrainerHeader4 call TalkToTrainer jp TextScriptEnd Route17BattleText5: TX_FAR _Route17BattleText5 db "@" Route17EndBattleText5: TX_FAR _Route17EndBattleText5 db "@" Route17AfterBattleText5: TX_FAR _Route17AfterBattleText5 db "@" Route17Text6: TX_ASM ld hl, Route17TrainerHeader5 call TalkToTrainer jp TextScriptEnd Route17BattleText6: TX_FAR _Route17BattleText6 db "@" Route17EndBattleText6: TX_FAR _Route17EndBattleText6 db "@" Route17AfterBattleText6: TX_FAR _Route17AfterBattleText6 db "@" Route17Text7: TX_ASM ld hl, Route17TrainerHeader6 call TalkToTrainer jp TextScriptEnd Route17BattleText7: TX_FAR _Route17BattleText7 db "@" Route17EndBattleText7: TX_FAR _Route17EndBattleText7 db "@" Route17AfterBattleText7: TX_FAR _Route17AfterBattleText7 db "@" Route17Text8: TX_ASM ld hl, Route17TrainerHeader7 call TalkToTrainer jp TextScriptEnd Route17BattleText8: TX_FAR _Route17BattleText8 db "@" Route17EndBattleText8: TX_FAR _Route17EndBattleText8 db "@" Route17AfterBattleText8: TX_FAR _Route17AfterBattleText8 db "@" Route17Text9: TX_ASM ld hl, Route17TrainerHeader8 call TalkToTrainer jp TextScriptEnd Route17BattleText9: TX_FAR _Route17BattleText9 db "@" Route17EndBattleText9: TX_FAR _Route17EndBattleText9 db "@" Route17AfterBattleText9: TX_FAR _Route17AfterBattleText9 db "@" Route17Text10: TX_ASM ld hl, Route17TrainerHeader9 call TalkToTrainer jp TextScriptEnd Route17BattleText10: TX_FAR _Route17BattleText10 db "@" Route17EndBattleText10: TX_FAR _Route17EndBattleText10 db "@" Route17AfterBattleText10: TX_FAR _Route17AfterBattleText10 db "@" Route17Text11: TX_FAR _Route17Text11 db "@" Route17Text12: TX_FAR _Route17Text12 db "@" Route17Text13: TX_FAR _Route17Text13 db "@" Route17Text14: TX_FAR _Route17Text14 db "@" Route17Text15: TX_FAR _Route17Text15 db "@" Route17Text16: TX_FAR _Route17Text16 db "@"
21.368902
52
0.829362
c5161469d7f3f56cce454513ccb64de4f18819ef
2,828
hpp
C++
engine/include/xe/graphics/types.hpp
trbflxr/xe
13123869a848972e064cb8c6838c4215f034f3d9
[ "MIT" ]
null
null
null
engine/include/xe/graphics/types.hpp
trbflxr/xe
13123869a848972e064cb8c6838c4215f034f3d9
[ "MIT" ]
null
null
null
engine/include/xe/graphics/types.hpp
trbflxr/xe
13123869a848972e064cb8c6838c4215f034f3d9
[ "MIT" ]
null
null
null
// // Created by trbflxr on 3/11/2020. // #ifndef XE_TYPES_HPP #define XE_TYPES_HPP #include <xe/common.hpp> namespace xe { enum class Usage { Static, Dynamic, Stream }; enum class BufferType { Invalid, Vertex, Index, Uniform }; enum class CubemapTarget { PositiveX, NegativeX, PositiveY, NegativeY, PositiveZ, NegativeZ, Invalid }; enum class TexelsFormat { None, R8, Rg8, Rgb8, Rgba8, R16f, Rg16f, Rgb16f, Rgba16f, Depth16, DepthStencil16, Depth24, DepthStencil24 }; enum class TextureWrap { Repeat, MirroredRepeat, Clamp }; enum class TextureMinFilter { Nearest, Linear, NearestMipmapNearest, NearestMipmapLinear, LinearMipmapNearest, LinearMipmapLinear }; enum class TextureMagFilter { Nearest, Linear }; enum class Primitive { Lines, Triangles, Points }; enum class Cull { Disabled, Front, Back }; enum class RenderMode { Disabled, Solid, Wireframe }; enum class TextureType { Invalid = 0, T1D, T2D, T3D, CubeMap }; enum class BlendFactor { Zero, One, SrcColor, OneMinusSrcColor, SrcAlpha, OneMinusSrcAlpha, DstColor, OneMinusDstColor, DstAlpha, OneMinusDstAlpha, SrcAlphaSaturated, BlendColor, OneMinusBlendColor, BlendAlpha, OneMinusBlendAlpha }; enum class BlendOp { Add, Substract, ReverseSubstract, Min, Max }; enum class CompareFunc { Disabled, Never, Less, LessEqual, Equal, NotEqual, GreaterEqual, Greater, Always }; struct VertexFormat { enum Enum { Undefined = 0, Float = 0x1, Int8 = 0x2, Uint8 = 0x3, Int16 = 0x4, Uint16 = 0x5, Int32 = 0x6, Uint32 = 0x7, Mat4 = 0x8, NumComponents1 = 0x10, NumComponents2 = 0x20, NumComponents3 = 0x30, NumComponents4 = 0x40, Normalized = 0x100, Int32_1 = Int32 | NumComponents1, Uint32_2 = Uint32 | NumComponents2, Float1 = Float | NumComponents1, Float2 = Float | NumComponents2, Float3 = Float | NumComponents3, Float4 = Float | NumComponents4, TypeMask = 0xF, TypeShift = 0, NumComponentsMask = 0xF0, NumComponentsShift = 4, FlagsMask = 0xF00, FlagsShift = 8 }; }; enum class VertexStep { PerVertex, PerInstance }; struct VertexDeclaration { const char *name; VertexFormat::Enum format; uint32_t bufferIndex; VertexStep vertexStep; uint32_t offset; uint32_t stride; }; enum class IndexFormat { Uint8, Uint16, Uint32 }; } #endif //XE_TYPES_HPP
14.57732
41
0.593352
c7ead2818710e3d62aeafd36d8f4963106b70a28
1,756
java
Java
algorithms/src/main/java/com/pjzhong/concurrency/example/managestate/impl/ConditionQueueBoundedBuffer.java
pjzhong/algorithms
bf8dfdcebd84a6bc93f0895ae995253380f2b233
[ "MIT" ]
1
2018-03-28T08:09:48.000Z
2018-03-28T08:09:48.000Z
algorithms/src/main/java/com/pjzhong/concurrency/example/managestate/impl/ConditionQueueBoundedBuffer.java
pjzhong/algorithms
bf8dfdcebd84a6bc93f0895ae995253380f2b233
[ "MIT" ]
12
2020-06-21T14:06:32.000Z
2022-01-04T16:47:36.000Z
algorithms/src/main/java/com/pjzhong/concurrency/example/managestate/impl/ConditionQueueBoundedBuffer.java
pjzhong/algorithms
bf8dfdcebd84a6bc93f0895ae995253380f2b233
[ "MIT" ]
null
null
null
package com.pjzhong.concurrency.example.managestate.impl; import java.util.concurrent.locks.Condition; import java.util.concurrent.locks.Lock; import java.util.concurrent.locks.ReentrantLock; /** * Lock can have as many condition objects as you want. * The equivalents of wait, notify, and notifyAll for Condition objects are await, signal * and signalAll. However, Condition extends Object, which means that it also has wait and notify methods. Be sure * to use the proper version - await and signal, signalAll - instead! * */ public class ConditionQueueBoundedBuffer<T> { protected final Lock lock = new ReentrantLock(); private final Condition notFull = lock.newCondition(); private final Condition notEmpty = lock.newCondition(); private int tail, head, count; private final T[] items; public ConditionQueueBoundedBuffer(int capacity) { this.items = (T[]) new Object[capacity]; } public void put(T x) throws InterruptedException { lock.lock(); try { while (count == items.length) { notFull.await(); } items[tail] = x; if(++tail == items.length) { tail = 0;} ++count; notEmpty.signal(); } finally { lock.unlock(); } } public T take() throws InterruptedException { lock.lock(); try { while (count == 0) { notEmpty.await(); } T x = items[head]; items[head] = null; if(++head == items.length) { head = 0; } --count; notFull.signal(); return x; } finally { lock.unlock(); } } }
29.762712
114
0.574032
047f3adb9b15dbf8bef01bb141f93772670631a2
2,852
java
Java
src/test/java/lee/t/code/DivideTwoIntegers.java
lichangshu/leetcode
7f30d0c51ee75cdf20c9b02299b0ac7601a4ef85
[ "MIT" ]
null
null
null
src/test/java/lee/t/code/DivideTwoIntegers.java
lichangshu/leetcode
7f30d0c51ee75cdf20c9b02299b0ac7601a4ef85
[ "MIT" ]
null
null
null
src/test/java/lee/t/code/DivideTwoIntegers.java
lichangshu/leetcode
7f30d0c51ee75cdf20c9b02299b0ac7601a4ef85
[ "MIT" ]
null
null
null
package lee.t.code; import org.junit.Assert; import org.junit.Test; /** * 给定两个整数,被除数 dividend 和除数 divisor。将两数相除,要求不使用乘法、除法和 mod 运算符。 * <p> * 返回被除数 dividend 除以除数 divisor 得到的商。 * <p> * 整数除法的结果应当截去(truncate)其小数部分,例如:truncate(8.345) = 8 以及 truncate(-2.7335) = -2 * <p> * 来源:力扣(LeetCode) * 链接:https://leetcode-cn.com/problems/divide-two-integers * 著作权归领扣网络所有。商业转载请联系官方授权,非商业转载请注明出处。 */ public class DivideTwoIntegers { // divisor >> i , dividend >> i /** * @param dividend * @param divisor * @return */ public int divide(int dividend, int divisor) { long val = positive(Math.abs((long) dividend), Math.abs((long) divisor)); if ((dividend ^ divisor) < 0) { val = 0 - val; } if (val > Integer.MAX_VALUE || val < Integer.MIN_VALUE) { return Integer.MAX_VALUE; } return (int) val; } public long positive(long dividend, long divisor) { if (dividend < divisor) { return 0; } int mv = 1; for (int i = 0; ; i++) { long v = divisor << i; if (dividend < v) { break; } mv = i; } long val = 1L << mv; return val + positive(dividend - (divisor << mv), divisor); } @Test public void test1() { Demo2 d = new Demo2(); { int d1 = Integer.MIN_VALUE, d2 = -1; int v = d.divide(d1, d2); Assert.assertEquals(Integer.MAX_VALUE, v); } { int d1 = 1651497, d2 = -156; int v = d.divide(d1, d2); Assert.assertEquals(d1 / d2, v); } } /** * over time ! */ public static class Demo2 { public int divide(int dividend, int divisor) { long val = positiveSum(Math.abs((long) dividend), Math.abs((long) divisor)); if ((dividend ^ divisor) < 0) { val = 0 - val; } if (val > Integer.MAX_VALUE || val < Integer.MIN_VALUE) { return Integer.MAX_VALUE; } return (int) val; } public long positiveSum(long dividend, long divisor) { long count = 0; for (long i = 1, sum = 0; ; i++) { sum += divisor; if (dividend < sum) { break; } count = i; } return count; } } @Test public void test2() { { int d1 = Integer.MIN_VALUE, d2 = -1; int v = this.divide(d1, d2); Assert.assertEquals(Integer.MAX_VALUE, v); } { int d1 = 1651497, d2 = -156; int v = this.divide(d1, d2); Assert.assertEquals(d1 / d2, v); } } }
25.464286
88
0.473703
5529c82fb0636ddd538ec3544403631496990218
1,290
lua
Lua
applications/luci-app-softethervpn/luasrc/model/cbi/softethervpn.lua
xuanwumen/luci
0122c16c1f60e357866baffbd9c3f0bba1ef0646
[ "Apache-2.0" ]
null
null
null
applications/luci-app-softethervpn/luasrc/model/cbi/softethervpn.lua
xuanwumen/luci
0122c16c1f60e357866baffbd9c3f0bba1ef0646
[ "Apache-2.0" ]
null
null
null
applications/luci-app-softethervpn/luasrc/model/cbi/softethervpn.lua
xuanwumen/luci
0122c16c1f60e357866baffbd9c3f0bba1ef0646
[ "Apache-2.0" ]
2
2021-09-11T08:19:41.000Z
2021-11-02T15:28:38.000Z
local s=require"luci.sys" local m,s,o m=Map("softethervpn",translate("SoftEther VPN")) m.description = translate("SoftEther VPN is an open source, cross-platform, multi-protocol virtual private network solution developed by university of tsukuba graduate student Daiyuu Nobori for master's thesis. <br>can easily set up OpenVPN, IPsec, L2TP, ms-sstp, L2TPv3 and EtherIP servers on the router using the console.") m.template="softethervpn/index" s=m:section(TypedSection,"softether") s.anonymous=true o=s:option(DummyValue,"softethervpn_status",translate("Current Condition")) o.template="softethervpn/status" o.value=translate("Collecting data...") o=s:option(Flag,"enable",translate("Enabled")) o.rmempty=false o=s:option(DummyValue,"moreinfo",translate("<strong>控制台下载:<a onclick=\"window.open('https://github.com/SoftEtherVPN/SoftEtherVPN_Stable/releases/download/v4.30-9696-beta/softether-vpnserver_vpnbridge-v4.30-9696-beta-2019.07.08-windows-x86_x64-intel.exe')\"><br/>Windows-x86_x64-intel.exe</a><a onclick=\"window.open('https://www.softether-download.com/files/softether/v4.21-9613-beta-2016.04.24-tree/Mac_OS_X/Admin_Tools/VPN_Server_Manager_Package/softether-vpnserver_manager-v4.21-9613-beta-2016.04.24-macos-x86-32bit.pkg')\"><br/>macos-x86-32bit.pkg</a></strong>")) return m
86
568
0.788372
72eb06b96222270d9ac7f17fbdb47e4b875eb54e
6,055
html
HTML
docs/articles/firststeps.html
Cataurus/TumblrSharp
9b8e9af3fe502086c4fecf890634d339940dd0bc
[ "MIT" ]
33
2016-08-17T22:15:56.000Z
2022-01-11T23:31:42.000Z
docs/articles/firststeps.html
Cataurus/TumblrSharp
9b8e9af3fe502086c4fecf890634d339940dd0bc
[ "MIT" ]
47
2016-05-19T10:50:04.000Z
2021-08-22T12:01:32.000Z
docs/articles/firststeps.html
piedoom/TumblrSharp
5bffcee52caba84b9495804b7ba303c0ec3d1348
[ "MIT" ]
33
2016-12-19T13:56:45.000Z
2022-01-11T23:31:48.000Z
<!DOCTYPE html> <!--[if IE]><![endif]--> <html> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> <title>First step </title> <meta name="viewport" content="width=device-width"> <meta name="title" content="First step "> <meta name="generator" content="docfx 2.52.0.0"> <link rel="shortcut icon" href="../favicon.ico"> <link rel="stylesheet" href="../styles/docfx.vendor.css"> <link rel="stylesheet" href="../styles/docfx.css"> <link rel="stylesheet" href="../styles/main.css"> <meta property="docfx:navrel" content="../toc.html"> <meta property="docfx:tocrel" content="toc.html"> </head> <body data-spy="scroll" data-target="#affix" data-offset="120"> <div id="wrapper"> <header> <nav id="autocollapse" class="navbar navbar-inverse ng-scope" role="navigation"> <div class="container"> <div class="navbar-header"> <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar"> <span class="sr-only">Toggle navigation</span> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </button> <a class="navbar-brand" href="../index.html"> <img id="logo" class="svg" src="../logo.svg" alt=""> </a> </div> <div class="collapse navbar-collapse" id="navbar"> <form class="navbar-form navbar-right" role="search" id="search"> <div class="form-group"> <input type="text" class="form-control" id="search-query" placeholder="Search" autocomplete="off"> </div> </form> </div> </div> </nav> <div class="subnav navbar navbar-default"> <div class="container hide-when-search" id="breadcrumb"> <ul class="breadcrumb"> <li></li> </ul> </div> </div> </header> <div role="main" class="container body-content hide-when-search"> <div class="sidenav hide-when-search"> <a class="btn toc-toggle collapse" data-toggle="collapse" href="#sidetoggle" aria-expanded="false" aria-controls="sidetoggle">Show / Hide Table of Contents</a> <div class="sidetoggle collapse" id="sidetoggle"> <div id="sidetoc"></div> </div> </div> <div class="article row grid-right"> <div class="col-md-10"> <article class="content wrap" id="_content" data-uid=""> <h1 id="first-step">First step</h1> <hr> <h2 id="nuget">Nuget</h2> <hr> <p>TumblrSharp is currently on Nuget as <code>NewTumblrSharp</code>. If you want TumblrSharp just for your own use, and don't wish to develop it further, simply use Nuget.</p> <h3 id="package-managment-console">Package-Managment-Console</h3> <pre><code class="lang-ps">Install-Package NewTumblrSharp </code></pre> <h3 id="nuget-manager">Nuget-Manager</h3> <p>Open the nuget-manager by right clicking on your project. In the searchbox type <code>NewTumblrSharp</code> and install.</p> <p><img src="../images/NugetManager_Install.png" alt="NugetManager"></p> <h2 id="source-code">Source code</h2> <hr> <p>If you'd like to use TumblrSharp via its source code to continue development, there are two methods.</p> <p>The following is for Visual Studio users, but the same steps can be used for Xamarin studio, etc. with little modification.</p> <h3 id="method-1-adding-projects-as-references">Method 1: Adding Projects as References</h3> <p>This method is preferred, as you can easily change the TumblrSharp source if needed without switching projects / reloading <code>.dll</code> files.</p> <ol> <li>Clone or download the repository</li> <li>Open the project in which you wish to use TumblrSharp</li> <li>Add project files to your solution. <ul> <li><p>for portable:</p> <ul> <li>src/portable/TumblrSharp/TumblrSharp.csproj</li> <li>src/portable/TumblrSharp.Client/Tumblrsharp.Client.csproj</li> </ul> </li> <li><p>for other:</p> <ul> <li>src/TumblrSharp/TumblrSharp.csproj</li> <li>src/TumblrSharp.Client/Tumblrsharp.Client.csproj</li> </ul> </li> </ul> </li> <li>Add references to all 2 newly added projects in your main project</li> </ol> <h3 id="method-2-compiling-and-adding-dlls">Method 2: Compiling and adding DLLs</h3> <ol> <li>Clone or download the repository</li> <li>Build all included projects</li> <li>Add references to the <code>.dll</code> files in your project, the files found in the directory <code>bin</code>.</li> </ol> </article> </div> <div class="hidden-sm col-md-2" role="complementary"> <div class="sideaffix"> <div class="contribution"> <ul class="nav"> <li> <a href="https://github.com/Cataurus/TumblrSharp/blob/master/docfx/articles/firststeps.md/#L1" class="contribution-link">Improve this Doc</a> </li> </ul> </div> <nav class="bs-docs-sidebar hidden-print hidden-xs hidden-sm affix" id="affix"> <!-- <p><a class="back-to-top" href="#top">Back to top</a><p> --> </nav> </div> </div> </div> </div> <footer> <div class="grad-bottom"></div> <div class="footer"> <div class="container"> <span class="pull-right"> <a href="#top">Back to top</a> </span> <span>Generated by <strong>DocFX</strong></span> </div> </div> </footer> </div> <script type="text/javascript" src="../styles/docfx.vendor.js"></script> <script type="text/javascript" src="../styles/docfx.js"></script> <script type="text/javascript" src="../styles/main.js"></script> </body> </html>
39.318182
176
0.591082
56f5541c866e9e6a1ac0436c65e8e56d8f6a4f0d
312
ts
TypeScript
client/app/components/login/user.model.ts
g2graman/NG6-Starter
f49cce178555f558df7084253995973fab91ee48
[ "Apache-2.0" ]
null
null
null
client/app/components/login/user.model.ts
g2graman/NG6-Starter
f49cce178555f558df7084253995973fab91ee48
[ "Apache-2.0" ]
null
null
null
client/app/components/login/user.model.ts
g2graman/NG6-Starter
f49cce178555f558df7084253995973fab91ee48
[ "Apache-2.0" ]
null
null
null
interface IUserModel { password: string; email: string; } class Model implements IUserModel { password: string; email: string; constructor ( password: string, email: string ) { this.password = password; this.email = email; } } export default Model;
15.6
35
0.599359
950cb64ddee092d85f78f1e6ca2eaa905149202c
704
kt
Kotlin
app/src/main/java/com/suda/yzune/wakeupschedule/suda_life/RoomAdapter.kt
XFY9326/WakeupSchedule_Kotlin
a69fb7555e0917e0ba8a0dadbf3248364666b089
[ "Apache-2.0" ]
581
2018-08-13T10:15:14.000Z
2022-03-17T03:41:31.000Z
app/src/main/java/com/suda/yzune/wakeupschedule/suda_life/RoomAdapter.kt
XFY9326/WakeupSchedule_Kotlin
a69fb7555e0917e0ba8a0dadbf3248364666b089
[ "Apache-2.0" ]
30
2018-09-02T07:41:35.000Z
2022-02-23T05:00:17.000Z
app/src/main/java/com/suda/yzune/wakeupschedule/suda_life/RoomAdapter.kt
XFY9326/WakeupSchedule_Kotlin
a69fb7555e0917e0ba8a0dadbf3248364666b089
[ "Apache-2.0" ]
106
2018-08-14T10:11:23.000Z
2022-02-27T17:31:09.000Z
package com.suda.yzune.wakeupschedule.suda_life import com.chad.library.adapter.base.BaseQuickAdapter import com.chad.library.adapter.base.viewholder.BaseViewHolder import com.suda.yzune.wakeupschedule.R import com.suda.yzune.wakeupschedule.bean.SudaRoomData import com.suda.yzune.wakeupschedule.widget.RoomView class RoomAdapter(layoutResId: Int, data: MutableList<SudaRoomData>) : BaseQuickAdapter<SudaRoomData, BaseViewHolder>(layoutResId, data) { override fun convert(helper: BaseViewHolder, item: SudaRoomData?) { if (item == null) return helper.getView<RoomView>(R.id.room_view).list = item.kfj.split(',') helper.setText(R.id.tv_room_name, item.jsbh) } }
39.111111
75
0.767045
810981aa9977f9b646c4d57f6386c96a12266846
157
go
Go
net/gicmp/ping_test.go
cryptowilliam/goutil
04ff8052d37b7ddd4bce6a776be5fa498eb829d7
[ "MIT" ]
2
2021-11-06T04:39:29.000Z
2021-11-15T09:53:57.000Z
net/gicmp/ping_test.go
cryptowilliam/goutil
04ff8052d37b7ddd4bce6a776be5fa498eb829d7
[ "MIT" ]
null
null
null
net/gicmp/ping_test.go
cryptowilliam/goutil
04ff8052d37b7ddd4bce6a776be5fa498eb829d7
[ "MIT" ]
1
2021-11-06T04:43:50.000Z
2021-11-06T04:43:50.000Z
package gicmp import ( "fmt" "testing" "time" ) func TestPing(t *testing.T) { sz := uint16(1200) fmt.Println(Ping("baidu.com", &sz, time.Second*5)) }
12.076923
51
0.636943
aefc4402581c07fbdbdaa0dfba8733b7d4069e13
2,206
swift
Swift
EmonCMSiOS/Apps/MySolar/MySolarAppViewModel.swift
emoncms/emoncms-ios
890938b23e8d0471727c074852bb46dc1769fa69
[ "MIT" ]
14
2016-12-22T04:42:11.000Z
2022-02-10T18:52:18.000Z
EmonCMSiOS/Apps/MySolar/MySolarAppViewModel.swift
emoncms/emoncms-ios
890938b23e8d0471727c074852bb46dc1769fa69
[ "MIT" ]
55
2016-11-11T10:55:38.000Z
2020-11-30T20:49:14.000Z
EmonCMSiOS/Apps/MySolar/MySolarAppViewModel.swift
emoncms/emoncms-ios
890938b23e8d0471727c074852bb46dc1769fa69
[ "MIT" ]
9
2016-12-01T16:58:14.000Z
2022-02-10T18:52:30.000Z
// // MySolarAppViewModel.swift // EmonCMSiOS // // Created by Matt Galloway on 27/12/2018. // Copyright © 2016 Matt Galloway. All rights reserved. // import Combine import Foundation import RealmSwift final class MySolarAppViewModel: AppViewModel { private let realmController: RealmController private let account: AccountController private let api: EmonCMSAPI private let realm: Realm private let appData: AppData // Inputs // Outputs let title: AnyPublisher<String, Never> let isReady: AnyPublisher<Bool, Never> var accessibilityIdentifier: String { return AccessibilityIdentifiers.Apps.MySolar } var pageViewControllerStoryboardIdentifiers: [String] { return ["mySolarPage1", "mySolarPage2"] } var pageViewModels: [AppPageViewModel] { return [self.page1ViewModel, self.page2ViewModel] } let page1ViewModel: MySolarAppPage1ViewModel let page2ViewModel: MySolarAppPage2ViewModel init(realmController: RealmController, account: AccountController, api: EmonCMSAPI, appDataId: String) { self.realmController = realmController self.account = account self.api = api self.realm = realmController.createAccountRealm(forAccountId: account.uuid) self.appData = self.realm.object(ofType: AppData.self, forPrimaryKey: appDataId)! self .page1ViewModel = MySolarAppPage1ViewModel(realmController: realmController, account: account, api: api, appDataId: appDataId) self .page2ViewModel = MySolarAppPage2ViewModel(realmController: realmController, account: account, api: api, appDataId: appDataId) self.title = self.appData.publisher(for: \.name) .receive(on: DispatchQueue.main) .eraseToAnyPublisher() self.isReady = self.appData.publisher(for: \.name) .map { $0 != "" } .receive(on: DispatchQueue.main) .eraseToAnyPublisher() } func configViewModel() -> AppConfigViewModel { return AppConfigViewModel(realmController: self.realmController, account: self.account, api: self.api, appDataId: self.appData.uuid, appCategory: .mySolar) } }
31.070423
110
0.701723
fe249359a7b9cd2312dfc51fbb2041a48fc67f89
922
c
C
99-saad/td1-6/td2/2-2.c
1gni5/3if-data-structure
f30910162fa8a555a4968b035ae4e68bd9a8d908
[ "MIT" ]
null
null
null
99-saad/td1-6/td2/2-2.c
1gni5/3if-data-structure
f30910162fa8a555a4968b035ae4e68bd9a8d908
[ "MIT" ]
null
null
null
99-saad/td1-6/td2/2-2.c
1gni5/3if-data-structure
f30910162fa8a555a4968b035ae4e68bd9a8d908
[ "MIT" ]
null
null
null
#include<stdio.h> int main() { int capacity,size = 0,in,i,j, objects[100]; scanf(" %d",&capacity); scanf(" %d",&in); while(in != -1) { objects[size] = in; scanf(" %d", &in); size++; } // declaration et initialization du tableau int tab[capacity+1]; tab[0] = 1; for(i = 1; i<capacity+1; i++) tab[i] = 0; for(i = 0; i<size;i++) { tab[objects[i]] = 1; } // remplissage du tableau, version non dynamique mais même complexité, i.e O(size*capacity) for(i=0;i<capacity+1;i++) { if(tab[i] == 1) { for(j = 0; j<size;j++) { tab[i+objects[j]] = 1; } } } // impression de tab, à enlever pour domjudge for(i = 0;i<capacity+1;i++) { printf("%d ", tab[i]); } printf("\n"); // if(tab[capacity]==1) { printf("OUI\r\n"); } else { printf("NON\r\n"); } return 0; }
18.44
94
0.477223
ffdd96f18dcae53ff400364f12379b4b985db140
11,941
html
HTML
Personal-Website.html
DeirdreHegarty/Dynamic-PHP-AJAX-Website
5c46ab8775a62e00a923316aa6467aa1ad421552
[ "MIT" ]
null
null
null
Personal-Website.html
DeirdreHegarty/Dynamic-PHP-AJAX-Website
5c46ab8775a62e00a923316aa6467aa1ad421552
[ "MIT" ]
null
null
null
Personal-Website.html
DeirdreHegarty/Dynamic-PHP-AJAX-Website
5c46ab8775a62e00a923316aa6467aa1ad421552
[ "MIT" ]
null
null
null
<!DOCTYPE> <html> <head> <title>Deirdre Hegarty</title> <meta charset="UTF-8"> <!-- NOTE TO SELF: jQuery needs to be before Bootstrap --> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script> <!-- Latest compiled and minified CSS --> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous"> <!-- Optional theme --> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap-theme.min.css" integrity="sha384-rHyoN1iRsVXV4nD0JutlnGaslCJuC7uwjduW9SVrLvRYooPp2bWYgmgJQIXwl/Sp" crossorigin="anonymous"> <!-- Latest compiled and minified JavaScript --> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script> <link rel="stylesheet" type="text/css" href="personal-website.css"> <script type="text/javascript" src="personal-website.js"></script> </head> <body id="body"> <nav class="navbar navbar-default"> <div class="container-fluid"> <!-- <div class="navbar-header"> --> <a class="navbar-brand" href="Personal-Website.html"> <img id="logo" alt="DH" src="logo/DH2.png"> </a> <!-- </div> --> <div class="navbar-form navbar-right dropdown" style='margin-right:5%;' autocomplete="off"> <!-- <form> --> <div class="form-group" data-toggle='dropdown'> <input type="text" class="form-control" placeholder="Search" id='inbox' onkeyup='suggestImages()' style="width:300px;float:left" autocomplete="off"> </div> <button id="b1" type="submit" form="hiddenform" class="btn btn-default" style="height:50px;margin-top:10px;padding-left:20px; padding-right:20px">Submit</button><br/> <div style='width:420px; padding-left:10px;'class='dropdown-menu'id='testdiv'>...<div> <!-- </form> --> </div> </div> <div id="imagediv"></div> <form style="display:none;" id='hiddenform' name='hiddenform' action='viewgallery.php' method='post'> <input id='hiddeninput' name='hiddeninput'> </form> </nav> <div id="container-one"class="container-fluid"> <div class="row"> <div class="col-md-6"> <p class="questions">WHO?</p> <p class="questions">WHAT?</p> <p class="questions">WHERE?</p> <p class="questions">WHEN?</p> <p class="questions">HOW?</p> </div> <div class="col-md-6"> <p id="whoAmI">Who needs labels? I am what I am. I am a creative, interested in all things beautiful.</p> </div> </div> </div> <div id='floating-squares' class="container-fluid"> <div class="row"> <div class='col-md-12 col-sm-12'> <div id="hid" class='hidden-xs' style='display:none;'> <!-- row 1 --> <div class='row'> <div class='small-squares-left'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> <div class='small-squares-right'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> </div> </div> </div> <!-- row 2 --> <div class='row'> <div class='small-squares-left'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> <div class='small-squares-right'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> </div> <!-- row 3 --> <div class='row'> <div class='small-squares-left'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> <div class='small-squares-right'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> </div> <!-- row 4 --> <div class='row'> <div class='small-squares-left'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> <div class='small-squares-right'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> </div> <!-- row 5 --> <div class='row'> <div class='small-squares-left'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> </div> </div> <div class='small-squares-right'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> </div> </div> <div id="orig" class='hidden-xs'> <h1 id='squares-text' style='z-index:-10; position: absolute; margin-left:32.5%; margin-top: 100px;'>Labels are boring</h1> <!-- row 1 --> <div class='row'> <div class='small-squares-left'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> </div> </div> <div class='small-squares-right'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> </div> <!-- row 2 --> <div class='row'> <div class='small-squares-left'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> <div class='small-squares-right'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> </div> <!-- row 3 --> <div class='row'> <div class='small-squares-left'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> <div class='small-squares-right'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> </div> <!-- row 4 --> <div class='row'> <div class='small-squares-left'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> <div class='small-squares-right'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> </div> <!-- row 5 --> <div class='row'> <div class='small-squares-left'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> <div class='small-squares-right'> <div class='col-md-6 col-sm-6 remove-padding'> <div class='small-squares'></div> </div> </div> </div> </div> <div class="visible-xs text-center"> <div class='row'> <div class='col-xs-12'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> <div class='row'> <div class='col-xs-12'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> <div class='row'> <div class='col-xs-12'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> <div class='row'> <div class='col-xs-12'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> <div class='row'> <div class='col-xs-12'> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> <div class='small-squares'></div> </div> </div> </div> </div> </div> </div> <!-- web dev --> <div class="container-fluid" id="beepboop"> <div class="row"> <h3>BEEP-BOOP-BEEP</h3> <div class="col-md-3 col-sm-6"><img class="boopImages" src="assets/logo.png"><p>Logos</p></div> <div class="col-md-3 col-sm-6"><img class="boopImages" src="assets/website.png"><p>Websites</p></div> <div class="col-md-3 col-sm-6"><img class="boopImages" src="assets/code.png"><p>Code Examples</p></div> <div class="col-md-3 col-sm-6"><img class="boopImages" src="assets/tutorial.png"><p>Tutorials</p></div> </div> </div> <!-- creative --> <div class="container-fluid" id="ohshiny"> <div class="row"> <h3>OH SHINY</h3> <div class="col-md-3"><img id="Painting" class="shinyimages" src="assets/painting.jpg"><p>painting</p></div> <div class="col-md-3"><img id="Sculpture" class="shinyimages" src="assets/sculpture.jpg"><p>sculpture</p></div> <div class="col-md-3"><img id="Photography" class="shinyimages" src="assets/photography.jpg"><p>photography</p></div> <div class="col-md-3"><img id="Film" class="shinyimages" src="assets/film.jpg"><p>film</p></div> </div> </div> <!-- contact form --> <div class="continer-fluid" id='container-three'> <div class="row"> <div class="col-md-6 text-center"> <h3>Contact Me</h3> </div> <div class='col-md-6'> <form id='contact-form'> <div class='form-group'> <input class='form-control' id='name' name='name' type='text' placeholder='name'> <input class='form-control' id='email' name='email' type='email' placeholder='your email address'> <textarea class='form-control' id='message' name='message' placeholder='message' style='height:150px;'></textarea> <button class='form-control' id='send' type='submit'> Send </button> </div> </form> </div> </div> </div> <div id='container-four' class="container-fluid"> <p>HELLO WORLD</p> </div> </body> <script> </script> </html>
34.611594
215
0.57558
706b01fced9522fbb96f5adda94b0d7cbbd27e71
4,078
go
Go
cmd/cluster-capacity/go/src/github.com/kubernetes-incubator/cluster-capacity/vendor/k8s.io/kubernetes/test/e2e_node/system/types.go
gbraad/openshift-origin
e3585cc68f89a7821bd0a37687c5b5d29b80a77d
[ "Apache-2.0" ]
37
2017-04-29T02:36:35.000Z
2021-01-20T17:00:28.000Z
cmd/cluster-capacity/go/src/github.com/kubernetes-incubator/cluster-capacity/vendor/k8s.io/kubernetes/test/e2e_node/system/types.go
gbraad/openshift-origin
e3585cc68f89a7821bd0a37687c5b5d29b80a77d
[ "Apache-2.0" ]
25
2017-05-01T18:18:04.000Z
2020-10-10T18:18:39.000Z
cmd/cluster-capacity/go/src/github.com/kubernetes-incubator/cluster-capacity/vendor/k8s.io/kubernetes/test/e2e_node/system/types.go
gbraad/openshift-origin
e3585cc68f89a7821bd0a37687c5b5d29b80a77d
[ "Apache-2.0" ]
33
2017-05-01T02:12:52.000Z
2021-04-19T09:13:55.000Z
/* Copyright 2016 The Kubernetes Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ package system // KernelConfig defines one kernel configration item. type KernelConfig struct { // Name is the general name of the kernel configuration. It is used to // match kernel configuration. Name string // Aliases are aliases of the kernel configuration. Some configuration // has different names in different kernel version. Names of different // versions will be treated as aliases. Aliases []string // Description is the description of the kernel configuration, for example: // * What is it used for? // * Why is it needed? // * Who needs it? Description string } // KernelSpec defines the specification for the kernel. Currently, it contains // specification for: // * Kernel Version // * Kernel Configuration type KernelSpec struct { // Versions define supported kernel version. It is a group of regexps. Versions []string // Required contains all kernel configurations required to be enabled // (built in or as module). Required []KernelConfig // Optional contains all kernel configurations are required for optional // features. Optional []KernelConfig // Forbidden contains all kernel configurations which areforbidden (disabled // or not set) Forbidden []KernelConfig } // DockerSpec defines the requirement configuration for docker. Currently, it only // contains spec for graph driver. type DockerSpec struct { // Version is a group of regex matching supported docker versions. Version []string // GraphDriver is the graph drivers supported by kubelet. GraphDriver []string } // RuntimeSpec is the abstract layer for different runtimes. Different runtimes // should put their spec inside the RuntimeSpec. type RuntimeSpec struct { *DockerSpec } // SysSpec defines the requirement of supported system. Currently, it only contains // spec for OS, Kernel and Cgroups. type SysSpec struct { // OS is the operating system of the SysSpec. OS string // KernelConfig defines the spec for kernel. KernelSpec KernelSpec // Cgroups is the required cgroups. Cgroups []string // RuntimeSpec defines the spec for runtime. RuntimeSpec RuntimeSpec } // DefaultSysSpec is the default SysSpec. var DefaultSysSpec = SysSpec{ OS: "Linux", KernelSpec: KernelSpec{ Versions: []string{`3\.[1-9][0-9].*`, `4\..*`}, // Requires 3.10+ or 4+ // TODO(random-liu): Add more config // TODO(random-liu): Add description for each kernel configuration: Required: []KernelConfig{ {Name: "NAMESPACES"}, {Name: "NET_NS"}, {Name: "PID_NS"}, {Name: "IPC_NS"}, {Name: "UTS_NS"}, {Name: "CGROUPS"}, {Name: "CGROUP_CPUACCT"}, {Name: "CGROUP_DEVICE"}, {Name: "CGROUP_FREEZER"}, {Name: "CGROUP_SCHED"}, {Name: "CPUSETS"}, {Name: "MEMCG"}, {Name: "INET"}, {Name: "EXT4_FS"}, {Name: "PROC_FS"}, {Name: "NETFILTER_XT_TARGET_REDIRECT", Aliases: []string{"IP_NF_TARGET_REDIRECT"}}, {Name: "NETFILTER_XT_MATCH_COMMENT"}, }, Optional: []KernelConfig{ {Name: "OVERLAY_FS", Aliases: []string{"OVERLAYFS_FS"}, Description: "Required for overlayfs."}, {Name: "AUFS_FS", Description: "Required for aufs."}, {Name: "BLK_DEV_DM", Description: "Required for devicemapper."}, }, Forbidden: []KernelConfig{}, }, Cgroups: []string{"cpu", "cpuacct", "cpuset", "devices", "freezer", "memory"}, RuntimeSpec: RuntimeSpec{ DockerSpec: &DockerSpec{ Version: []string{`1\.(9|1[0-2])\..*`}, // Requires 1.9+ // TODO(random-liu): Validate overlay2. GraphDriver: []string{"aufs", "overlay", "devicemapper"}, }, }, }
33.154472
99
0.71898
d70e3e1d314cff8cf9b8b57d200d5d8e634eb72b
40
sql
SQL
app/addons/discussion/database/demo_ultimate.sql
vortex52/checkout-questions
2d5fe5eed438e0066a0152bd6afdde9f49ca8fc9
[ "MIT" ]
1
2020-04-29T23:53:49.000Z
2020-04-29T23:53:49.000Z
app/addons/discussion/database/demo_ultimate.sql
vortex52/checkout-questions
2d5fe5eed438e0066a0152bd6afdde9f49ca8fc9
[ "MIT" ]
5
2020-05-27T18:26:12.000Z
2021-09-02T10:33:14.000Z
app/addons/discussion/database/demo_ultimate.sql
vortex52/checkout-questions
2d5fe5eed438e0066a0152bd6afdde9f49ca8fc9
[ "MIT" ]
1
2021-04-18T03:41:32.000Z
2021-04-18T03:41:32.000Z
UPDATE ?:discussion SET company_id = 1;
20
39
0.75
ae9fac8e3309d9ca06b1eeb4acd7bfd6287ade97
365
swift
Swift
RxQRScanner/Classes/ImagePickerController.swift
xiao99xiao/RxQRScanner
341063fd1921cf8f2c8928e516a47a3212f0a903
[ "MIT" ]
12
2018-02-25T11:38:10.000Z
2021-11-17T09:58:04.000Z
RxQRScanner/Classes/ImagePickerController.swift
xiao99xiao/RxQRScanner
341063fd1921cf8f2c8928e516a47a3212f0a903
[ "MIT" ]
null
null
null
RxQRScanner/Classes/ImagePickerController.swift
xiao99xiao/RxQRScanner
341063fd1921cf8f2c8928e516a47a3212f0a903
[ "MIT" ]
2
2019-01-20T01:56:11.000Z
2020-03-28T02:28:42.000Z
// // ImagePickerController.swift // RxQRScanner // // Created by duan on 2019/07/23. // import UIKit class ImagePickerController: UIImagePickerController { var statusBarStyle: UIStatusBarStyle = .default { didSet { setNeedsStatusBarAppearanceUpdate() } } override var preferredStatusBarStyle: UIStatusBarStyle { return statusBarStyle } }
21.470588
84
0.736986
10eb3f5fc5ccd5a00a3af0b1e70392dd99114de5
21,715
sql
SQL
db-init/init.sql
Bluberia/AREA
e034c44dac5e389a1607e11c7729f55f31119277
[ "CECILL-B" ]
null
null
null
db-init/init.sql
Bluberia/AREA
e034c44dac5e389a1607e11c7729f55f31119277
[ "CECILL-B" ]
null
null
null
db-init/init.sql
Bluberia/AREA
e034c44dac5e389a1607e11c7729f55f31119277
[ "CECILL-B" ]
null
null
null
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8 */; /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; /*!40103 SET TIME_ZONE='+00:00' */; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; -- -- Table structure for table `actions` -- use `area`; DROP TABLE IF EXISTS `actions`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `actions` ( `id` int(11) NOT NULL AUTO_INCREMENT, `service_id` int(11) NOT NULL, `name` varchar(100) NOT NULL, `description` text NOT NULL, `parameters` json DEFAULT NULL, `results` json DEFAULT NULL, PRIMARY KEY (`id`), UNIQUE KEY `action name` (`name`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `actions` -- -- LOCK TABLES `actions` WRITE; INSERT INTO `actions` VALUES (0, 0, "push", "a new push is intended by someone", '{"username": "string", "repository": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (1, 0, "pull_request", "a new pull request is intended by someone", '{"username": "string", "repository": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (2, 1, "tweet", "a new tweet has been post", '{}', '{"user": "string", "message": "string"}'); INSERT INTO `actions` VALUES (3, 2, "playlist_modified", "A music has been added or deleted from a playlist", '{"playlistId": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (4, 3, "messaged_received", "A new message has been received", '{"server": "string", "channel": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (5, 3, "a_user_joined", "A new user has joined the server", '{"server": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (6, 3, "a_user_is_banned", "A user has been ban from the server", '{"server": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (7, 3, "channel_created", "A channel has been created on the server", '{"server": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (8, 4, "timer", "Do an action at min interval", '{"interval": "int"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (9, 5, "file_added", "A file has been add on the server", '{}', '{"name": "string", "user": "string"}'); INSERT INTO `actions` VALUES (10, 5, "file_deleted", "A file has been deleted on the server", '{}', '{"name": "string", "user": "string"}'); /*!40000 ALTER TABLE `actions` DISABLE KEYS */; /*!40000 ALTER TABLE `actions` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Table structure for table `github` -- /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `github` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `username` varchar(50) NOT NULL, `repo_name` varchar(50) NOT NULL, `webhook_type`varchar(50) NOT NULL, PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `area` -- /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `area` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `action_id` int(11) NOT NULL, `reaction_id` int(11) NOT NULL, `parameters_action` json DEFAULT NULL, `parameters_reaction` json DEFAULT NULL, PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `area` -- -- LOCK TABLES `area` WRITE; /*!40000 ALTER TABLE `area` DISABLE KEYS */; /*!40000 ALTER TABLE `area` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Table structure for table `reactions` -- /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `dropbox` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `dropbox_id` varchar(200) NOT NULL, `dropbox_cursor` varchar(200) NOT NULL, UNIQUE KEY `service client_id` (`client_id`), PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `timer` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `area_id` int(11) NOT NULL, `interval_timer` int(11) NOT NULL, `current_timer` int(11) NOT NULL, PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `spotify` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `area_id` int(11) NOT NULL, `tracks` TEXT NOT NULL, PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `url_callback` ( `id` int(11) NOT NULL AUTO_INCREMENT, `url_id` varchar(15) NOT NULL, `url` varchar(200) NOT NULL, `client_id` int(11) DEFAULT NULL, PRIMARY KEY (`id`), UNIQUE KEY `service name` (`url_id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; DROP TABLE IF EXISTS `reactions`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `reactions` ( `id` int(11) NOT NULL AUTO_INCREMENT, `service_id` int(11) NOT NULL, `name` varchar(50) NOT NULL, `description` text NOT NULL, `parameters` json DEFAULT NULL, PRIMARY KEY (`id`), UNIQUE KEY `service name` (`name`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `reactions` -- -- LOCK TABLES `reactions` WRITE; INSERT INTO `reactions` VALUES (0, 1, "tweet", "post a new tweet", '{"message": "string"}'); INSERT INTO `reactions` VALUES (1, 2, "add_music", "add a new music to an existing playlist", '{"music": "string", "playlist": "string"}'); INSERT INTO `reactions` VALUES (2, 2, "play_music", "play a music on your devise", '{"music": "string"}'); INSERT INTO `reactions` VALUES (3, 2, "pause_music", "pause the music on your devise if playing", '{}'); INSERT INTO `reactions` VALUES (4, 2, "add_to_queue", "add a music to the player queue", '{"music": "string"}'); INSERT INTO `reactions` VALUES (5, 3, "send_message", "send a message to a specific channel", '{"server" : "string", "channel": "string", "message": "string"}'); INSERT INTO `reactions` VALUES (6, 3, "create_channel", "create a channel", '{"server" : "string", "channel": "string"}'); INSERT INTO `reactions` VALUES (7, 6, "send_mail", "send a mail", '{"to": "string", "subject": "string", "message": "string"}'); /*!40000 ALTER TABLE `reactions` DISABLE KEYS */; /*!40000 ALTER TABLE `reactions` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Table structure for table `services` -- DROP TABLE IF EXISTS `services`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `services` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(50) NOT NULL, `oauth` boolean NOT NULL DEFAULT 0, PRIMARY KEY (`id`), UNIQUE KEY `service name` (`name`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `services` -- -- LOCK TABLES `services` WRITE; /*!40000 ALTER TABLE `services` DISABLE KEYS */; INSERT INTO `services` VALUES (0,'github', 1); INSERT INTO `services` VALUES (1,'twitter', 1); INSERT INTO `services` VALUES (2,'spotify', 1); INSERT INTO `services` VALUES (3,'discord', 0); INSERT INTO `services` VALUES (4,'timer', 0); INSERT INTO `services` VALUES (5,'dropbox', 1); INSERT INTO `services` VALUES (6,'mail', 0); /*!40000 ALTER TABLE `services` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Table structure for table `services_auth` -- /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `services_auth` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `service_id` int(11) NOT NULL, `access_token` varchar(500) DEFAULT NULL, `refresh_token` varchar(500) DEFAULT NULL, `secret_token` varchar(500) DEFAULT NULL, PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `services_auth` -- -- LOCK TABLES `services_auth` WRITE; /*!40000 ALTER TABLE `services_auth` DISABLE KEYS */; /*!40000 ALTER TABLE `services_auth` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Table structure for table `tokens` -- /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `tokens` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `token` varchar(200) DEFAULT NULL, PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `tokens` -- -- LOCK TABLES `tokens` WRITE; /*!40000 ALTER TABLE `tokens` DISABLE KEYS */; /*!40000 ALTER TABLE `tokens` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Table structure for table `users` -- /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `users` ( `id` int(11) NOT NULL AUTO_INCREMENT, `username` varchar(50) NOT NULL, `email` varchar(100) NOT NULL, `password` varchar(70) NOT NULL, `is_oauth2` boolean NOT NULL DEFAULT 0, PRIMARY KEY (`id`), UNIQUE KEY `user email` (`email`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `users` -- -- LOCK TABLES `users` WRITE; /*!40000 ALTER TABLE `users` DISABLE KEYS */; /*!40000 ALTER TABLE `users` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Dumping routines for database 'area' -- /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; /*!40101 SET SQL_MODE=@OLD_SQL_MODE */; /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */; /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; CREATE DATABASE IF NOT EXISTS `area_test`; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8 */; /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; /*!40103 SET TIME_ZONE='+00:00' */; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; -- -- Table structure for table `actions` -- use `area_test`; DROP TABLE IF EXISTS `actions`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `actions` ( `id` int(11) NOT NULL AUTO_INCREMENT, `service_id` int(11) NOT NULL, `name` varchar(100) NOT NULL, `description` text NOT NULL, `parameters` json DEFAULT NULL, `results` json DEFAULT NULL, PRIMARY KEY (`id`), UNIQUE KEY `action name` (`name`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `actions` -- -- LOCK TABLES `actions` WRITE; INSERT INTO `actions` VALUES (0, 0, "push", "a new push is intended by someone", '{"repository": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (1, 0, "pull_request", "a new pull request is intended by someone", '{"repository": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (2, 1, "tweet", "a new tweet has been post", '{}', '{"message": "string"}'); INSERT INTO `actions` VALUES (3, 2, "playlist_modified", "A music has been added or deleted from a playlist", '{"playlistId": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (4, 3, "messaged_received", "A new message has been received", '{"server": "string", "channel": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (5, 3, "a_user_joined", "A new user has joined the server", '{"server": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (6, 3, "a_user_is_banned", "A user has been ban from the server", '{"server": "string"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (7, 4, "timer", "Do an action at min interval", '{"interval": "int"}', '{"message": "string"}'); INSERT INTO `actions` VALUES (8, 5, "file_added", "A file has been add on the server", '{}', '{"message": "string"}'); INSERT INTO `actions` VALUES (9, 5, "file_deleted", "A file has been deleted on the server", '{}', '{"message": "string"}'); /*!40000 ALTER TABLE `actions` DISABLE KEYS */; /*!40000 ALTER TABLE `actions` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Table structure for table `area` -- /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `area` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `action_id` int(11) NOT NULL, `reaction_id` int(11) NOT NULL, `parameters_action` json DEFAULT NULL, `parameters_reaction` json DEFAULT NULL, PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `area` -- -- LOCK TABLES `area` WRITE; /*!40000 ALTER TABLE `area` DISABLE KEYS */; /*!40000 ALTER TABLE `area` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Table structure for table `reactions` -- /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `dropbox` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `dropbox_id` varchar(200) NOT NULL, `dropbox_cursor` varchar(200) NOT NULL, UNIQUE KEY `service client_id` (`client_id`), PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `timer` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `area_id` int(11) NOT NULL, `interval_timer` int(11) NOT NULL, `current_timer` int(11) NOT NULL, PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `spotify` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `area_id` int(11) NOT NULL, `tracks` TEXT NOT NULL, PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `url_callback` ( `id` int(11) NOT NULL AUTO_INCREMENT, `url_id` varchar(15) NOT NULL, `url` varchar(200) NOT NULL, `client_id` int(11) DEFAULT NULL, PRIMARY KEY (`id`), UNIQUE KEY `service name` (`url_id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; DROP TABLE IF EXISTS `reactions`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `reactions` ( `id` int(11) NOT NULL AUTO_INCREMENT, `service_id` int(11) NOT NULL, `name` varchar(50) NOT NULL, `description` text NOT NULL, `parameters` json DEFAULT NULL, PRIMARY KEY (`id`), UNIQUE KEY `service name` (`name`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `reactions` -- -- LOCK TABLES `reactions` WRITE; INSERT INTO `reactions` VALUES (0, 1, "tweet", "post a new tweet", '{"message": "string"}'); INSERT INTO `reactions` VALUES (1, 2, "add_music", "add a new music to an existing playlist", '{"music": "string", "playlist": "string"}'); INSERT INTO `reactions` VALUES (2, 2, "play_music", "play a music on your devise", '{"music": "string"}'); INSERT INTO `reactions` VALUES (3, 2, "pause_music", "pause the music on your devise if playing", '{}'); INSERT INTO `reactions` VALUES (4, 2, "add_to_queue", "add a music to the player queue", '{"music": "string"}'); INSERT INTO `reactions` VALUES (5, 3, "send_message", "send a message to a specific channel", '{"message": "string", "channel": "string"}'); INSERT INTO `reactions` VALUES (6, 3, "create_channel", "create a channel", '{"channel": "string"}'); INSERT INTO `reactions` VALUES (7, 6, "send_mail", "send a mail", '{"to": "string", "subject": "string", "message": "string"}'); /*!40000 ALTER TABLE `reactions` DISABLE KEYS */; /*!40000 ALTER TABLE `reactions` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Table structure for table `services` -- DROP TABLE IF EXISTS `services`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `services` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(50) NOT NULL, `oauth` boolean NOT NULL DEFAULT 0, PRIMARY KEY (`id`), UNIQUE KEY `service name` (`name`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `services` -- -- LOCK TABLES `services` WRITE; /*!40000 ALTER TABLE `services` DISABLE KEYS */; INSERT INTO `services` VALUES (0,'github', 1); INSERT INTO `services` VALUES (1,'twitter', 1); INSERT INTO `services` VALUES (2,'spotify', 1); INSERT INTO `services` VALUES (3,'discord', 0); INSERT INTO `services` VALUES (4,'timer', 0); INSERT INTO `services` VALUES (5,'dropbox', 1); INSERT INTO `services` VALUES (6,'mail', 0); /*!40000 ALTER TABLE `services` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Table structure for table `services_auth` -- /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `services_auth` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `service_id` int(11) NOT NULL, `access_token` varchar(500) DEFAULT NULL, `refresh_token` varchar(500) DEFAULT NULL, `secret_token` varchar(500) DEFAULT NULL, PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `services_auth` -- -- LOCK TABLES `services_auth` WRITE; /*!40000 ALTER TABLE `services_auth` DISABLE KEYS */; /*!40000 ALTER TABLE `services_auth` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Table structure for table `tokens` -- /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `tokens` ( `id` int(11) NOT NULL AUTO_INCREMENT, `client_id` int(11) NOT NULL, `token` varchar(200) DEFAULT NULL, PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `tokens` -- -- LOCK TABLES `tokens` WRITE; /*!40000 ALTER TABLE `tokens` DISABLE KEYS */; /*!40000 ALTER TABLE `tokens` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Table structure for table `users` -- /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `users` ( `id` int(11) NOT NULL AUTO_INCREMENT, `username` varchar(50) NOT NULL, `email` varchar(100) NOT NULL, `password` varchar(70) NOT NULL, `is_oauth2` boolean NOT NULL DEFAULT 0, PRIMARY KEY (`id`), UNIQUE KEY `user email` (`email`) ) DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `users` -- -- LOCK TABLES `users` WRITE; /*!40000 ALTER TABLE `users` DISABLE KEYS */; /*!40000 ALTER TABLE `users` ENABLE KEYS */; -- UNLOCK TABLES; -- -- Dumping routines for database 'area' -- /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; /*!40101 SET SQL_MODE=@OLD_SQL_MODE */; /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */; /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
35.833333
173
0.664748
4627f1f0312ee730f47487efa0f794e2e11e6424
14,699
sql
SQL
PAK_ZIP_1.sql
mirmas/InteractivePrints
26afbc05bcd379b6412dd06459f17124daaf1916
[ "MIT" ]
4
2018-07-17T14:34:33.000Z
2020-09-18T13:51:16.000Z
PAK_ZIP_1.sql
mirmas/InteractivePrints
26afbc05bcd379b6412dd06459f17124daaf1916
[ "MIT" ]
null
null
null
PAK_ZIP_1.sql
mirmas/InteractivePrints
26afbc05bcd379b6412dd06459f17124daaf1916
[ "MIT" ]
2
2019-12-30T20:31:22.000Z
2020-08-04T06:36:03.000Z
CREATE OR REPLACE PACKAGE BODY "PAK_ZIP" AS -- Interactive Prints using the following MIT License: -- -- The MIT License (MIT) -- -- Copyright (c) 2021 Mirmas IC -- -- Permission is hereby granted, free of charge, to any person obtaining a copy -- of this software and associated documentation files (the "Software"), to deal -- in the Software without restriction, including without limitation the rights -- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -- copies of the Software, and to permit persons to whom the Software is -- furnished to do so, subject to the following conditions: -- -- The above copyright notice and this permission notice shall be included in all -- copies or substantial portions of the Software. -- -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -- SOFTWARE. c_LOCAL_FILE_HEADER constant raw(4) := hextoraw( '504B0304' ); -- Local file header signature c_END_OF_CENTRAL_DIRECTORY constant raw(4) := hextoraw( '504B0506' ); -- End of central directory signature -- function blob2num( p_blob blob, p_len integer, p_pos integer ) return number is rv number; begin rv := utl_raw.cast_to_binary_integer( dbms_lob.substr( p_blob, p_len, p_pos ), utl_raw.little_endian ); if rv < 0 then rv := rv + 4294967296; end if; return rv; end; function raw2varchar2( p_raw raw, p_encoding varchar2 ) return varchar2 is begin return coalesce( utl_i18n.raw_to_char( p_raw, p_encoding ) , utl_i18n.raw_to_char( p_raw, utl_i18n.map_charset( p_encoding, utl_i18n.GENERIC_CONTEXT, utl_i18n.IANA_TO_ORACLE ) ) ); end; function little_endian( p_big in number, p_bytes in pls_integer := 4 ) return raw is begin return utl_raw.substr( utl_raw.cast_from_binary_integer( p_big, utl_raw.little_endian ), 1, p_bytes ); exception when others then pak_xslt_log.WriteLog ( p_description => 'Error p_big '||p_big||' p_bytes '||p_bytes , p_log_type => pak_xslt_log.g_error , p_procedure => 'pak_zip.little_endian' , P_SQLERRM => sqlerrm ); raise; end little_endian; -- procedure add1file ( p_zipped_blob in out blob , p_name in varchar2 , p_content in blob ) is t_now date; t_blob blob; t_clen integer; begin t_now := sysdate; t_blob := utl_compress.lz_compress( p_content ); t_clen := dbms_lob.getlength( t_blob ); if p_zipped_blob is null then dbms_lob.createtemporary( p_zipped_blob, true ); end if; dbms_lob.append( p_zipped_blob , utl_raw.concat( hextoraw( '504B0304' ) -- Local file header signature , hextoraw( '1400' ) -- version 2.0 , hextoraw( '0000' ) -- no General purpose bits , hextoraw( '0800' ) -- deflate , little_endian( to_number( to_char( t_now, 'ss' ) ) / 2 + to_number( to_char( t_now, 'mi' ) ) * 32 + to_number( to_char( t_now, 'hh24' ) ) * 2048 , 2 ) -- File last modification time , little_endian( to_number( to_char( t_now, 'dd' ) ) + to_number( to_char( t_now, 'mm' ) ) * 32 + ( to_number( to_char( t_now, 'yyyy' ) ) - 1980 ) * 512 , 2 ) -- File last modification date , dbms_lob.substr( t_blob, 4, t_clen - 7 ) -- CRC-32 , little_endian( t_clen - 18 ) -- compressed size , little_endian( dbms_lob.getlength( p_content ) ) -- uncompressed size , little_endian( length( p_name ), 2 ) -- File name length , hextoraw( '0000' ) -- Extra field length , utl_raw.cast_to_raw( p_name ) -- File name ) ); --dbms_lob.append( p_zipped_blob, dbms_lob.substr( t_blob, t_clen - 18, 11 ) ); -- compressed content --doesn't work if t_clen > 32K DBMS_LOB.COPY ( -- compressed content p_zipped_blob, t_blob, t_clen - 18, dbms_lob.getlength(p_zipped_blob) + 1, 11 ); dbms_lob.freetemporary( t_blob ); exception when others then pak_xslt_log.WriteLog ( p_description => 'Error p_name '||p_name , p_log_type => pak_xslt_log.g_error , p_procedure => 'pak_zip.add1file' , P_SQLERRM => sqlerrm ); raise; end add1file; -- procedure finish_zip( p_zipped_blob in out blob, p_comment varchar2 default 'Zipped by Region2XSLTReport software http://www.mirmas.si' ) is t_cnt pls_integer := 0; t_offs integer; t_offs_dir_header integer; t_offs_end_header integer; t_comment raw(32767) := utl_raw.cast_to_raw(p_comment); begin t_offs_dir_header := dbms_lob.getlength( p_zipped_blob ); t_offs := dbms_lob.instr( p_zipped_blob, hextoraw( '504B0304' ), 1 ); while t_offs > 0 loop t_cnt := t_cnt + 1; dbms_lob.append( p_zipped_blob , utl_raw.concat( hextoraw( '504B0102' ) -- Central directory file header signature , hextoraw( '1400' ) -- version 2.0 , dbms_lob.substr( p_zipped_blob, 26, t_offs + 4 ) , hextoraw( '0000' ) -- File comment length , hextoraw( '0000' ) -- Disk number where file starts , hextoraw( '0100' ) -- Internal file attributes , hextoraw( '2000B681' ) -- External file attributes , little_endian( t_offs - 1 ) -- Relative offset of local file header , dbms_lob.substr( p_zipped_blob , utl_raw.cast_to_binary_integer( dbms_lob.substr( p_zipped_blob, 2, t_offs + 26 ), utl_raw.little_endian ) , t_offs + 30 ) -- File name ) ); t_offs := dbms_lob.instr( p_zipped_blob, hextoraw( '504B0304' ), t_offs + 32 ); end loop; t_offs_end_header := dbms_lob.getlength( p_zipped_blob ); dbms_lob.append( p_zipped_blob , utl_raw.concat( hextoraw( '504B0506' ) -- End of central directory signature , hextoraw( '0000' ) -- Number of this disk , hextoraw( '0000' ) -- Disk where central directory starts , little_endian( t_cnt, 2 ) -- Number of central directory records on this disk , little_endian( t_cnt, 2 ) -- Total number of central directory records , little_endian( t_offs_end_header - t_offs_dir_header ) -- Size of central directory , little_endian( t_offs_dir_header ) -- Relative offset of local file header , little_endian( nvl( utl_raw.length( t_comment ), 0 ), 2 ) -- ZIP file comment length , t_comment ) ); exception when others then pak_xslt_log.WriteLog ( p_description => 'Error' , p_log_type => pak_xslt_log.g_error , p_procedure => 'pak_zip.finish_zip' , P_SQLERRM => sqlerrm ); raise; end finish_zip; -- $if CCOMPILING.g_utl_file_privilege $then procedure save_zip ( p_zipped_blob in blob , p_dir in varchar2 , p_filename in varchar2 ) is t_fh utl_file.file_type; t_len pls_integer := 32767; begin t_fh := utl_file.fopen( p_dir, p_filename, 'wb' ); for i in 0 .. trunc( ( dbms_lob.getlength( p_zipped_blob ) - 1 ) / t_len ) loop utl_file.put_raw( t_fh, dbms_lob.substr( p_zipped_blob, t_len, i * t_len + 1 ) ); end loop; utl_file.fclose( t_fh ); exception when others then pak_xslt_log.WriteLog ( p_description => 'Error p_dir '||p_dir||' p_filename '||p_filename , p_log_type => pak_xslt_log.g_error , p_procedure => 'pak_zip.save_zip' , P_SQLERRM => sqlerrm ); raise; end save_zip; $end function compressText(p_content CLOB, p_file_name varchar2 :='Region2XSLTReport') return BLOB as l_zipped_blob blob; l_suorce_blob blob; begin l_suorce_blob := pak_blob_util.CLOB2BLOB(p_content, NLS_CHARSET_ID('AL32UTF8')); add1file(l_zipped_blob, p_file_name, l_suorce_blob); finish_zip(l_zipped_blob); return l_zipped_blob; end compressText; function get_file ( p_zipped_blob blob , p_file_name varchar2 , p_encoding varchar2 := null ) return blob is t_tmp blob; t_ind integer; t_hd_ind integer; t_fl_ind integer; t_encoding varchar2(32767); t_len integer; begin t_ind := dbms_lob.getlength( p_zipped_blob ) - 21; loop exit when t_ind < 1 or dbms_lob.substr( p_zipped_blob, 4, t_ind ) = c_END_OF_CENTRAL_DIRECTORY; t_ind := t_ind - 1; end loop; -- if t_ind <= 0 then return null; end if; -- t_hd_ind := blob2num( p_zipped_blob, 4, t_ind + 16 ) + 1; for i in 1 .. blob2num( p_zipped_blob, 2, t_ind + 8 ) loop if p_encoding is null then if utl_raw.bit_and( dbms_lob.substr( p_zipped_blob, 1, t_hd_ind + 9 ), hextoraw( '08' ) ) = hextoraw( '08' ) then t_encoding := 'UTF8'; -- utf8 else t_encoding := 'US8PC437'; -- IBM codepage 437 end if; else t_encoding := p_encoding; end if; if p_file_name = raw2varchar2 ( dbms_lob.substr( p_zipped_blob , blob2num( p_zipped_blob, 2, t_hd_ind + 28 ) , t_hd_ind + 46 ) , t_encoding ) then t_len := blob2num( p_zipped_blob, 4, t_hd_ind + 24 ); -- uncompressed length if t_len = 0 then if substr( p_file_name, -1 ) in ( '/', '\' ) then -- directory/folder return null; else -- empty file return empty_blob(); end if; end if; -- if dbms_lob.substr( p_zipped_blob, 2, t_hd_ind + 10 ) = hextoraw( '0800' ) -- deflate then t_fl_ind := blob2num( p_zipped_blob, 4, t_hd_ind + 42 ); t_tmp := hextoraw( '1F8B0800000000000003' ); -- gzip header dbms_lob.copy( t_tmp , p_zipped_blob , blob2num( p_zipped_blob, 4, t_hd_ind + 20 ) , 11 , t_fl_ind + 31 + blob2num( p_zipped_blob, 2, t_fl_ind + 27 ) -- File name length + blob2num( p_zipped_blob, 2, t_fl_ind + 29 ) -- Extra field length ); dbms_lob.append( t_tmp, utl_raw.concat( dbms_lob.substr( p_zipped_blob, 4, t_hd_ind + 16 ) -- CRC32 , little_endian( t_len ) -- uncompressed length ) ); return utl_compress.lz_uncompress( t_tmp ); end if; -- if dbms_lob.substr( p_zipped_blob, 2, t_hd_ind + 10 ) = hextoraw( '0000' ) -- The file is stored (no compression) then t_fl_ind := blob2num( p_zipped_blob, 4, t_hd_ind + 42 ); dbms_lob.createtemporary( t_tmp, true ); dbms_lob.copy( t_tmp , p_zipped_blob , t_len , 1 , t_fl_ind + 31 + blob2num( p_zipped_blob, 2, t_fl_ind + 27 ) -- File name length + blob2num( p_zipped_blob, 2, t_fl_ind + 29 ) -- Extra field length ); return t_tmp; end if; end if; t_hd_ind := t_hd_ind + 46 + blob2num( p_zipped_blob, 2, t_hd_ind + 28 ) -- File name length + blob2num( p_zipped_blob, 2, t_hd_ind + 30 ) -- Extra field length + blob2num( p_zipped_blob, 2, t_hd_ind + 32 ); -- File comment length end loop; -- return null; end; function decompressToText ( p_zipped_blob blob , p_file_name varchar2 :='Region2XSLTReport' ) return clob as begin return pak_blob_util.BLOB2CLOB(get_file(p_zipped_blob, p_file_name, NLS_CHARSET_ID('AL32UTF8')),NLS_CHARSET_ID('AL32UTF8')); end decompressToText; function decompress ( p_zipped_blob blob , p_file_name varchar2 :='Region2XSLTReport' ) return blob as begin return get_file(p_zipped_blob, p_file_name, NLS_CHARSET_ID('AL32UTF8')); end decompress; END PAK_ZIP; /
41.640227
162
0.521192
66c34fe956bdc6399ba8f728c05d9bc7f57204da
756
dart
Dart
lib/api/Organisation.dart
danielbotn/foosball_mobile_app
6f2824c5b20d3b1674fea8068c7b1853331d193a
[ "MIT" ]
null
null
null
lib/api/Organisation.dart
danielbotn/foosball_mobile_app
6f2824c5b20d3b1674fea8068c7b1853331d193a
[ "MIT" ]
null
null
null
lib/api/Organisation.dart
danielbotn/foosball_mobile_app
6f2824c5b20d3b1674fea8068c7b1853331d193a
[ "MIT" ]
null
null
null
import 'package:flutter/foundation.dart'; import 'package:flutter_dotenv/flutter_dotenv.dart'; import 'package:http/http.dart' as http; class Organisation { final String token; Organisation({required this.token}); Future<http.Response> getOrganisationById(int organisationId) async { late http.Response result; String? baseUrl = kReleaseMode ? dotenv.env['REST_URL_PATH_PROD'] : dotenv.env['REST_URL_PATH_DEV']; if (baseUrl != null) { var url = Uri.parse(baseUrl + '/api/Organisations/' + organisationId.toString()); result = await http.get(url, headers: { "Accept": "application/json", "content-type": "application/json", 'Authorization': 'Bearer $token', }); } return result; } }
30.24
104
0.679894
a75d43b59a4e108451f43e9b382fcbff4f137d9d
595
swift
Swift
iosApp/GitHubViewer/AppGitHubViewer.swift
keygenqt/kmm-GitHubViewer
7a000741c8f8c21a559de8afb0cff0a2358a24d8
[ "Apache-2.0" ]
21
2021-11-29T19:41:24.000Z
2022-02-20T04:00:13.000Z
iosApp/GitHubViewer/AppGitHubViewer.swift
keygenqt/kmm-GitHubViewer
7a000741c8f8c21a559de8afb0cff0a2358a24d8
[ "Apache-2.0" ]
null
null
null
iosApp/GitHubViewer/AppGitHubViewer.swift
keygenqt/kmm-GitHubViewer
7a000741c8f8c21a559de8afb0cff0a2358a24d8
[ "Apache-2.0" ]
2
2022-01-06T04:37:29.000Z
2022-01-13T08:34:53.000Z
// // GitHubViewerApp.swift // GitHubViewer // // Created by Виталий Зарубин on 05.10.2021. // import Firebase import SwiftUI @main struct AppGitHubViewer: App { @UIApplicationDelegateAdaptor private var appDelegate: AppDelegate var body: some Scene { WindowGroup { NavGraph() } } class AppDelegate: NSObject, UIApplicationDelegate { func application(_: UIApplication, didFinishLaunchingWithOptions _: [UIApplication.LaunchOptionsKey: Any]? = nil) -> Bool { FirebaseApp.configure() return true } } }
21.25
131
0.652101
3ebcd734a14cded1470b120766dd4f4032f9c4e0
420
lua
Lua
framework/mahjong/init.lua
yinlei/tgame
f4ecee138a8d4d1f43ea6cadfe4d97c92b7b2028
[ "MIT" ]
3
2017-11-04T10:32:42.000Z
2019-03-21T12:33:55.000Z
framework/mahjong/init.lua
yinlei/tgame
f4ecee138a8d4d1f43ea6cadfe4d97c92b7b2028
[ "MIT" ]
null
null
null
framework/mahjong/init.lua
yinlei/tgame
f4ecee138a8d4d1f43ea6cadfe4d97c92b7b2028
[ "MIT" ]
2
2019-03-12T09:54:07.000Z
2021-02-19T05:03:01.000Z
-------------------------------------------------------------------------------- -- mahjong -------------------------------------------------------------------------------- local _PACKAGE = string.gsub(...,"%.","/") or "" local INFO_MSG = tengine.INFO_MSG local DEBUG_MSG = tengine.DEBUG_MSG local ERROR_MSG = tengine.ERROR_MSG local p = tengine.p local _M = require(_PACKAGE.."/mahjong") require(_PACKAGE.."/shuffle")
35
80
0.440476
19e4c5193ef21deb5419c1d27c7d6d0174b02b3e
1,494
go
Go
readme/readme.go
hazbo/cli-1
8817314a865c5c5b2ee076d9af0e4fb7d43c523f
[ "0BSD" ]
1
2019-05-05T13:14:40.000Z
2019-05-05T13:14:40.000Z
readme/readme.go
hazbo/cli-1
8817314a865c5c5b2ee076d9af0e4fb7d43c523f
[ "0BSD" ]
null
null
null
readme/readme.go
hazbo/cli-1
8817314a865c5c5b2ee076d9af0e4fb7d43c523f
[ "0BSD" ]
null
null
null
package readme import "errors" import "io/ioutil" import "os" import "path" import "regexp" // READMEPattern matches README file names. var READMEPattern = regexp.MustCompile(`(?i)^readme(\.(txt|md|markdown|mdown|mkdn|textile|rdoc|org|creole|mediawiki|wiki|rst|asciidoc|adoc|asc|pod))?$`) // FindREADME returns the file name of a README in the directory. func FindREADME(directoryPath string) (string, error) { // Read the entries in the directory. directory, err := os.Open(directoryPath) if err != nil { return "", err } defer directory.Close() entries, err := directory.Readdir(-1) if err != nil { return "", err } // Compile a list of names that match our pattern. var matches []string for _, entry := range entries { if entry.Mode()&os.ModeType != 0 { // Not a regular file. continue } name := entry.Name() if READMEPattern.MatchString(name) { matches = append(matches, name) } } if len(matches) == 0 { return "", errors.New("could not find README file") } if len(matches) != 1 { return "", errors.New("found multiple README files") } return matches[0], nil } // ReadREADME returns the file name and contents of the README in a directory. func ReadREADME(directoryPath string) (string, []byte, error) { fileName, err := FindREADME(directoryPath) if err != nil { return "", nil, err } path := path.Join(directoryPath, fileName) data, err := ioutil.ReadFile(path) if err != nil { return "", nil, err } return fileName, data, nil }
25.758621
152
0.684739
a9c7d66d36ee3082f2b68d2e22da0fe70c04a450
11,720
html
HTML
prospective/index.html
swabhs/swabhs.github.io
4528d15061fc0d1887cdf0354964e83936ea2e30
[ "MIT" ]
1
2021-06-25T19:16:46.000Z
2021-06-25T19:16:46.000Z
prospective/index.html
swabhs/swabhs.github.io
4528d15061fc0d1887cdf0354964e83936ea2e30
[ "MIT" ]
null
null
null
prospective/index.html
swabhs/swabhs.github.io
4528d15061fc0d1887cdf0354964e83936ea2e30
[ "MIT" ]
9
2020-12-04T03:48:28.000Z
2022-02-08T07:13:38.000Z
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <title>Swabha Swayamdipta | prospective students</title> <meta name="description" content=""> <!-- Open Graph --> <!-- Bootstrap & MDB --> <link href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css" rel="stylesheet" integrity="sha512-MoRNloxbStBcD8z3M/2BmnT+rg4IsMxPkXaGh2zD6LGNNFE80W3onsAhRcMAMrSoyWL9xD7Ert0men7vR8LUZg==" crossorigin="anonymous"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/mdbootstrap/4.19.1/css/mdb.min.css" integrity="sha512-RO38pBRxYH3SoOprtPTD86JFOclM51/XTIdEPh5j8sj4tp8jmQIx26twG52UaLi//hQldfrh7e51WzP9wuP32Q==" crossorigin="anonymous" /> <!-- Fonts & Icons --> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.14.0/css/all.min.css" integrity="sha512-1PKOgIY59xJ8Co8+NE6FZ+LOAZKjy+KY8iq0G4B3CyeY6wYHN3yt9PW0XpSriVlkMXe40PTKnXrLnZ9+fkDaog==" crossorigin="anonymous"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/academicons/1.9.0/css/academicons.min.css" integrity="sha512-W4yqoT1+8NLkinBLBZko+dFB2ZbHsYLDdr50VElllRcNt2Q4/GSs6u71UHKxB7S6JEMCp5Ve4xjh3eGQl/HRvg==" crossorigin="anonymous"> <link rel="stylesheet" type="text/css" href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700|Roboto+Slab:100,300,400,500,700|Material+Icons"> <!-- Code Syntax Highlighting --> <link rel="stylesheet" href="https://gitcdn.link/repo/jwarby/jekyll-pygments-themes/master/github.css" /> <!-- Styles --> <link rel="shortcut icon" href="/assets/img/favicon.ico"> <link rel="stylesheet" href="/assets/css/main.css"> <link rel="canonical" href="/prospective/"> <!-- Theming--> <!-- MathJax --> <script defer type="text/javascript" id="MathJax-script" src="https://cdn.jsdelivr.net/npm/mathjax@3.1.2/es5/tex-mml-chtml.js"></script> <script defer src="https://polyfill.io/v3/polyfill.min.js?features=es6"></script> </head> <body class="fixed-top-nav "> <!-- Header --> <header> <!-- Nav Bar --> <nav id="navbar" class="navbar navbar-light navbar-expand-sm fixed-top"> <div class="container"> <a class="navbar-brand title font-weight-lighter" href="/"> <span class="font-weight-bold">Swabha</span> </a> <!-- Social Icons --> <div class="row ml-1 ml-sm-0"> <span class="contact-icon text-center"> <a href="mailto:%73%77%61%62%68%61%73@%61%6C%6C%65%6E%61%69.%6F%72%67"><i class="fas fa-envelope"></i></a> <a href="https://scholar.google.com/citations?user=3uTVQt0AAAAJ" target="_blank" title="Google Scholar"><i class="ai ai-google-scholar"></i></a> <a href="https://semanticscholar.com/author/2705113" target="_blank" title="Semantic Scholar"><i class="ai ai-semantic-scholar"></i></a> <a href="https://github.com/swabhs" target="_blank" title="GitHub"><i class="fab fa-github"></i></a> <a href="https://twitter.com/swabhz" target="_blank" title="Twitter"><i class="fab fa-twitter"></i></a> </span> </div> <!-- Navbar Toogle --> <button class="navbar-toggler collapsed ml-auto" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation"> <span class="sr-only">Toggle navigation</span> <span class="icon-bar top-bar"></span> <span class="icon-bar middle-bar"></span> <span class="icon-bar bottom-bar"></span> </button> <div class="collapse navbar-collapse text-right" id="navbarNav"> <ul class="navbar-nav ml-auto flex-nowrap"> <!-- About --> <li class="nav-item "> <a class="nav-link" href="/"> about </a> </li> <!-- Other pages --> <li class="nav-item "> <a class="nav-link" href="/cv/"> cv </a> </li> <li class="nav-item "> <a class="nav-link" href="/mentoring/"> mentoring </a> </li> <li class="nav-item "> <a class="nav-link" href="/projects/"> projects </a> </li> <li class="nav-item "> <a class="nav-link" href="/publications/"> publications </a> </li> <li class="nav-item "> <a class="nav-link" href="/talks/"> talks </a> </li> </ul> </div> </div> </nav> </header> <!-- Content --> <div class="container mt-5"> <div class="post"> <header class="post-header"> <h1 class="post-title">prospective students</h1> <p class="desc"></p> </header> <article> <p>   </p> <h3 id="am-i-recruiting">Am I recruiting?</h3> <p>Yes, I am actively recruiting PhD students to USC in 🍁 Fall 2022! Thanks for your interest ☀️ in my research! <a href="https://www.cs.usc.edu/ph-d-application-information/">Applications</a> are open, and the deadline to submit your application is <a href="https://days.to/until/15-december">Dec 15th, 2021</a>. USC waived GRE scores ⚡ for graduate admissions in Fall 2022 and offers <a href="https://gradadm.usc.edu/lightboxes/us-students-fee-waivers/">fee waivers</a> to select applicants.</p> <p>Please consider <u>selecting</u> <a href="https://www.cs.usc.edu/directory/faculty/profile/?lname=Swayamdipta&amp;fname=Swabha">my name</a> <u>as a potential advisor</u>, especially if your research interests match <a href="/publications/">mine</a>, even though your research background might be different. I’m broadly interested in</p> <hr /> <h5 id="-estimation-of-dataset-quality">📚 Estimation of Dataset Quality:</h5> <p>What makes a dataset valuable for training high-capacity models, pretrained on large amounts of unlabeled data? Our <a href="https://arxiv.org/abs/2009.10795">Dataset Cartography</a> offers point estimates, and <a href="https://arxiv.org/abs/2110.08420">V-Information</a> offers aggregate estimates of dataset quality. Can these estimates be computed without taking into account specific model families?</p> <h6 id="-creative-data-curation">🎨 Creative Data Curation:</h6> <p>Can we use the lessons above to create high quality datasets, more suitable for modern NLP models? Our work on <a href="https://arxiv.org/abs/2004.11546">Generative Data Augmentation</a> showed that this is possible to automate to some extent, either via <a href="https://arxiv.org/abs/2105.03023">controlled generation</a> or <a href="https://arxiv.org/abs/2004.10964">selection</a>. Is it possible to create collaborative setups between humans and generative models to this end?</p> <h5 id="-robustness-to-model-biases">🤖 Robustness to Model Biases:</h5> <!-- Given that one of the loftiest goals in machine learning is generalization, we need to ensure that --> <p>Current large scale models tend to <a href="https://arxiv.org/abs/1803.02324">rely on spurious biases to make the correct predictions</a>. The reduction of undesirable biases could be done via data selection, as in <a href="https://arxiv.org/abs/2002.04108">AFLite</a> or by altering the <a href="https://arxiv.org/abs/1909.03683">learning objectives</a>. However, the discovery of such biases is much trickier and task-dependent. Going beyond solutions presented in <a href="https://arxiv.org/abs/2002.04108">AFLite</a>, how can we find spurious correlations automatically?</p> <p>Particularly harmful are social biases in models, such as those which correlate surface markers of certain dialects with subjective attributes such as toxicity. <a href="https://arxiv.org/abs/2102.00086">Social biases cannot be mitigated easily</a> and require rethinking data collection and task design, as we show in our <a href="https://arxiv.org/abs/2111.07997">latest paper</a>.</p> <h5 id="️-model-interpretability-and--meticulous-evaluation">🕵🏼‍♀️ Model Interpretability and 👩🏼‍🔬 Meticulous Evaluation:</h5> <p>What cannot be measured, cannot be improved. How can we make our <a href="https://arxiv.org/abs/2103.01378">models explain their decisions to human users</a>? Moreover, as tasks previously considered extremely difficult are getting easier, how do we best <a href="https://arxiv.org/abs/2102.01454">adapt our evaluation methods</a> to ensure fair evaluation?</p> <hr /> <h3 id="should-you-send-me-an-email">Should you send me an email?</h3> <h6 id="if-youre-not-at-usc">If you’re NOT at USC:</h6> <p>You do <em>not</em> have to email me, especially since I haven’t officially started at USC and do not have any control over the admissions process. My recommendation to you is to apply through the regular PhD program <a href="https://www.cs.usc.edu/ph-d-application-information/">admissions</a> by December 15th and USC will be in touch with you regarding the next steps. I will go over every single application that lists me as a potential advisor. 🤞</p> <h6 id="if-youre-already-at-usc">If you’re already at USC:</h6> <p>Please feel free to email me if you are looking for advising or TA positions. However, you should know that there is not much I can officially do, just yet. It would be great to be introduced and learn about your interests, though! 👋</p> </article> </div> </div> <!-- Footer --> <footer class="fixed-bottom"> <div class="container mt-0"> &copy; Copyright 2021 Swabha Swayamdipta. Powered by <a href="http://jekyllrb.com/" target="_blank">Jekyll</a> with <a href="https://github.com/alshedivat/al-folio">al-folio</a> theme. </div> </footer> </body> <!-- jQuery --> <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.1/jquery.min.js" integrity="sha512-bLT0Qm9VnAYZDflyKcBaQ2gg0hSYNQrJ8RilYldYQ1FxQYoCLtUjuuRuZo+fjqhx/qtq/1itJ0C2ejDxltZVFg==" crossorigin="anonymous"></script> <!-- Bootsrap & MDB scripts --> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.4.4/umd/popper.min.js" integrity="sha512-eUQ9hGdLjBjY3F41CScH3UX+4JDSI9zXeroz7hJ+RteoCaY+GP/LDoM8AO+Pt+DRFw3nXqsjh9Zsts8hnYv8/A==" crossorigin="anonymous"></script> <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js" integrity="sha512-M5KW3ztuIICmVIhjSqXe01oV2bpe248gOxqmlcYrEzAvws7Pw3z6BK0iGbrwvdrUQUhi3eXgtxp5I8PDo9YfjQ==" crossorigin="anonymous"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/mdbootstrap/4.19.1/js/mdb.min.js" integrity="sha512-Mug9KHKmroQFMLm93zGrjhibM2z2Obg9l6qFG2qKjXEXkMp/VDkI4uju9m4QKPjWSwQ6O2qzZEnJDEeCw0Blcw==" crossorigin="anonymous"></script> <!-- Mansory & imagesLoaded --> <script defer src="https://unpkg.com/masonry-layout@4/dist/masonry.pkgd.min.js"></script> <script defer src="https://unpkg.com/imagesloaded@4/imagesloaded.pkgd.min.js"></script> <script defer src="/assets/js/mansory.js" type="text/javascript"></script> <!-- Load Common JS --> <script src="/assets/js/common.js"></script> <!-- Load DarkMode JS --> <script src="/assets/js/dark_mode.js"></script> </html>
43.088235
487
0.658106
8623d81b9b5df97e19591cd755e7b98edc171272
239
asm
Assembly
libsrc/gfx/portable/setpos.asm
Frodevan/z88dk
f27af9fe840ff995c63c80a73673ba7ee33fffac
[ "ClArtistic" ]
640
2017-01-14T23:33:45.000Z
2022-03-30T11:28:42.000Z
libsrc/gfx/portable/setpos.asm
Frodevan/z88dk
f27af9fe840ff995c63c80a73673ba7ee33fffac
[ "ClArtistic" ]
1,600
2017-01-15T16:12:02.000Z
2022-03-31T12:11:12.000Z
libsrc/gfx/portable/setpos.asm
Frodevan/z88dk
f27af9fe840ff995c63c80a73673ba7ee33fffac
[ "ClArtistic" ]
215
2017-01-17T10:43:03.000Z
2022-03-23T17:25:02.000Z
SECTION code_graphics PUBLIC setpos PUBLIC _setpos EXTERN __gfx_coords ; void setpos(int x, int y) __smallc setpos: _setpos: ld hl,sp+2 ld d,(hl) ld hl,sp+4 ld e,(hl) ld hl,__gfx_coords ld (hl),e inc hl ld (hl),d ret
9.192308
36
0.669456
9712fe64165d1593baea415de57f15a250bd1ece
595
sql
SQL
IT Infrastructure/Database/New Database/SQL/node_gateways.sql
Azzziel/Lulus-Online
1964b834690f584d13484241a5a2391a50c924c4
[ "MIT" ]
null
null
null
IT Infrastructure/Database/New Database/SQL/node_gateways.sql
Azzziel/Lulus-Online
1964b834690f584d13484241a5a2391a50c924c4
[ "MIT" ]
6
2021-03-10T13:27:54.000Z
2022-02-27T02:28:08.000Z
IT Infrastructure/Database/New Database/SQL/node_gateways.sql
Azzziel/Lulus-Online
1964b834690f584d13484241a5a2391a50c924c4
[ "MIT" ]
1
2020-03-23T08:18:26.000Z
2020-03-23T08:18:26.000Z
DROP TABLE IF EXISTS `onspotmy_node_db`.`node_gateways`; CREATE TABLE `onspotmy_node_db`.`node_gateways` ( `index` INT UNSIGNED AUTO_INCREMENT NOT NULL, `lc_id` INT UNSIGNED NOT NULL, `gtwy_id` CHAR(4) NOT NULL, `fl_id` INT UNSIGNED NOT NULL, PRIMARY KEY (`lc_id`, `gtwy_id`), FOREIGN KEY (`lc_id`, `gtwy_id`) REFERENCES `node_nodes` (`lc_id`, `node_id`), FOREIGN KEY (`fl_id`) REFERENCES `node_floors` (`fl_id`), UNIQUE `UNIQUE_INDEX` (`index`) ) ENGINE = InnoDB; INSERT INTO `onspotmy_node_db`.`node_gateways` (`lc_id`, `gtwy_id`, `fl_id`) VALUES (1, 'AAA1', 1);
42.5
81
0.685714
41087d78b03b9000103c88d3f16bb2eeee4df52f
2,066
h
C
OAML/shared/Include/oamlSfxTrack.h
Shchvova/solar2d-plugins
d207849706372ef3a611fcaac5a0b599d9023d22
[ "MIT" ]
78
2016-06-07T06:42:48.000Z
2022-01-10T01:18:48.000Z
OAML/shared/Include/oamlSfxTrack.h
Shchvova/solar2d-plugins
d207849706372ef3a611fcaac5a0b599d9023d22
[ "MIT" ]
5
2016-02-11T11:53:36.000Z
2016-05-15T20:47:02.000Z
OAML/shared/Include/oamlSfxTrack.h
Shchvova/solar2d-plugins
d207849706372ef3a611fcaac5a0b599d9023d22
[ "MIT" ]
9
2016-06-15T12:11:15.000Z
2021-04-28T07:27:20.000Z
//----------------------------------------------------------------------------- // Copyright (c) 2015-2018 Marcelo Fernandez // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to // deal in the Software without restriction, including without limitation the // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or // sell copies of the Software, and to permit persons to whom the Software is // furnished to do so, subject to the following conditions: // // The above copyright notice and this permission notice shall be included in // all copies or substantial portions of the Software. // // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS // IN THE SOFTWARE. //----------------------------------------------------------------------------- #ifndef __OAMLSFXTRACK_H__ #define __OAMLSFXTRACK_H__ class ByteBuffer; class oamlAudio; typedef struct { oamlAudio *audio; int pos; float vol; float pan; } sfxPlayInfo; class oamlSfxTrack : public oamlTrack { private: std::vector<oamlAudio*> sfxAudios; std::vector<sfxPlayInfo> playingAudios; public: oamlSfxTrack(bool _verbose); ~oamlSfxTrack(); void GetAudioList(std::vector<std::string>& list); void AddAudio(oamlAudio *audio); oamlAudio* GetAudio(std::string filename); oamlRC Play(const char *name, float vol, float pan); void Stop(); bool IsPlaying(); std::string GetPlayingInfo(); void Mix(float *samples, int channels, bool debugClipping); bool IsSfxTrack() const { return true; } void ReadInfo(oamlTrackInfo *info); void FreeMemory(); }; #endif
32.28125
79
0.698451
775432f476179e6ddfd7438b32b9dd5b59fb30fb
33
kts
Kotlin
addOns/help_hu_HU/help_hu_HU.gradle.kts
jarcelo/zap-core-help
1635903dc632e5572f1c2abb4f230f1c060a3128
[ "Apache-2.0" ]
221
2015-06-03T14:57:40.000Z
2022-02-25T21:30:13.000Z
addOns/help_hu_HU/help_hu_HU.gradle.kts
jarcelo/zap-core-help
1635903dc632e5572f1c2abb4f230f1c060a3128
[ "Apache-2.0" ]
152
2015-06-24T10:26:44.000Z
2022-03-28T08:43:26.000Z
addOns/help_hu_HU/help_hu_HU.gradle.kts
jarcelo/zap-core-help
1635903dc632e5572f1c2abb4f230f1c060a3128
[ "Apache-2.0" ]
144
2015-06-02T16:37:36.000Z
2022-03-21T17:27:37.000Z
extra["language"] = "Hungarian"
11
31
0.666667
8713f9b3afcdbe0d08bb52b840fd28f0b3386624
1,758
ps1
PowerShell
scripts/normalize.ps1
SplitGemini/windowsterminal-shell
545ae111fb94dbbf043413d2f1dd9e6ae4ce62e8
[ "MIT" ]
2
2021-03-29T00:45:35.000Z
2022-02-07T19:32:34.000Z
scripts/normalize.ps1
SplitGemini/windowsterminal-shell
545ae111fb94dbbf043413d2f1dd9e6ae4ce62e8
[ "MIT" ]
null
null
null
scripts/normalize.ps1
SplitGemini/windowsterminal-shell
545ae111fb94dbbf043413d2f1dd9e6ae4ce62e8
[ "MIT" ]
null
null
null
[CmdletBinding()] param( [Parameter(Position = 0, ValueFromRemainingArguments=$true)] [string[]] $Paths ) # 不支持wildcard $output = join-path -path $(get-location).Path -ChildPath "output" if (!(test-path -LiteralPath $output)){ New-Item -ItemType Directory -Force -Path $output } $extension = ".m4a", ".mp3", ".wav" function RunInDir([string]$path) { Write-Host "Solving `"$path`"" Get-ChildItem -LiteralPath $path -File | Where-Object { $extension -contains $_.Extension} | ` ForEach-Object { RunInFile $_ } } function RunInFile([Parameter(Mandatory = $true)]$path) { $out = join-path -Path $output -ChildPath $path.Name $newvid = [io.path]::ChangeExtension($out, '.m4a') Write-Host "Start normalize" $path ffmpeg -y -hide_banner -i $path.FullName -threads 8 -af "loudnorm=i=-23.0:lra=7.0:tp=-2.0:" -ar 48000 -vn $newvid } if ($Paths -and ($Paths.count -gt 0)) { foreach ($path in $Paths) { $path = [Management.Automation.WildcardPattern]::Unescape($path) try { $path = Convert-Path -LiteralPath $path $path = Get-Item -LiteralPath $path # 获取后缀 另一种方法[System.IO.Path]::GetExtension if (!$path.PSIsContainer -and ($extension -contains $Path.Extension)) { RunInFile $Path } elseif ($path.PSIsContainer){ RunInDir $Path } else { Write-Host "`"$path`" not surported." } } catch { Write-Host "`"$path`" doesn't exists or not surported. Error $_" } } } else { RunInDir $(get-location).Path } Write-Host '完成' if (!$IsWindowsTerminal) { Read-Host "Press any key to continue." }
29.3
117
0.583618
22d86071af9fc656bad88d5d3f2b1b5ebaddd293
389
cpp
C++
src/strtod/strtod_lemire.cpp
ibireme/c_numconv_benchmark
3129f75c9cd9070a98fdd5d3e19a817ecf5c929d
[ "MIT" ]
38
2020-10-15T01:44:40.000Z
2022-01-20T07:10:54.000Z
src/strtod/strtod_lemire.cpp
ibireme/c_numconv_benchmark
3129f75c9cd9070a98fdd5d3e19a817ecf5c929d
[ "MIT" ]
3
2020-10-15T00:41:48.000Z
2020-10-18T13:35:04.000Z
src/strtod/strtod_lemire.cpp
ibireme/c_numconv_benchmark
3129f75c9cd9070a98fdd5d3e19a817ecf5c929d
[ "MIT" ]
2
2020-10-15T04:36:49.000Z
2022-02-23T04:04:46.000Z
/* Code from https://github.com/lemire/fast_double_parser */ #include "fast_double_parser.h" extern "C" double strtod_lemire(const char *str, size_t len, char **endptr) { double val; bool suc = fast_double_parser::parse_number(str, &val); if (suc) { *endptr = (char *)str + len; } else { *endptr = (char *)str; val = 0.0; } return val; }
21.611111
66
0.598972
16a2af47b67da3cd36974dd8d2567d9f3d36f683
532
ts
TypeScript
src/@types/querystringify.d.ts
trustpilot/skift
c9b13c95d80d74b70e39b71854675ad3cfedc369
[ "MIT" ]
25
2017-06-01T11:57:17.000Z
2019-12-23T09:40:56.000Z
src/@types/querystringify.d.ts
trustpilot/skift
c9b13c95d80d74b70e39b71854675ad3cfedc369
[ "MIT" ]
56
2017-06-01T11:54:06.000Z
2020-09-07T07:09:05.000Z
src/@types/querystringify.d.ts
trustpilot/skift
c9b13c95d80d74b70e39b71854675ad3cfedc369
[ "MIT" ]
null
null
null
declare module 'querystringify' { /** * Simple query string parser. * @param query The query string that needs to be parsed. */ export function parse(query: string): { [key: string]: string; }; /** * Transform an object to a query string. * @param obj Object that should be transformed. * @param prefix Optional prefix. Default prefix is '?' when passing true. Pass a string to use a custom prefix. */ export function stringify(obj: object, prefix?: boolean | string): string; }
35.466667
116
0.652256
92205b4566fad59995c4b5cbb7208bf1f1244dad
425
ps1
PowerShell
nuget.package/tools/net45/install.ps1
Mervill/NLua
7c178c3d50902c15234f1e84e2b3d85bd5b961a9
[ "MIT" ]
3
2016-12-11T10:42:17.000Z
2017-06-12T21:57:26.000Z
nuget.package/tools/net45/install.ps1
GibTreaty/NLua
26031db68cadceb1325e2ba2667d18719147264a
[ "MIT" ]
2
2016-03-05T17:52:59.000Z
2017-01-12T19:24:28.000Z
nuget.package/tools/net45/install.ps1
GibTreaty/NLua
26031db68cadceb1325e2ba2667d18719147264a
[ "MIT" ]
5
2016-03-05T07:54:44.000Z
2019-08-08T20:14:19.000Z
param($installPath, $toolsPath, $package, $project) . (Join-Path $toolsPath "GetLibLuaPostBuildCmd.ps1") # Get the current Post Build Event cmd $currentPostBuildCmd = $project.Properties.Item("PostBuildEvent").Value # Append our post build command if it's not already there if (!$currentPostBuildCmd.Contains($LibLuaPostBuildCmd)) { $project.Properties.Item("PostBuildEvent").Value += $LibLuaPostBuildCmd }
35.416667
76
0.750588
6b4c8407a6125312d436339fc286449a2133c52d
1,590
asm
Assembly
programs/oeis/007/A007742.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
1
2021-03-15T11:38:20.000Z
2021-03-15T11:38:20.000Z
programs/oeis/007/A007742.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
programs/oeis/007/A007742.asm
karttu/loda
9c3b0fc57b810302220c044a9d17db733c76a598
[ "Apache-2.0" ]
null
null
null
; A007742: a(n) = n*(4*n+1). ; 0,5,18,39,68,105,150,203,264,333,410,495,588,689,798,915,1040,1173,1314,1463,1620,1785,1958,2139,2328,2525,2730,2943,3164,3393,3630,3875,4128,4389,4658,4935,5220,5513,5814,6123,6440,6765,7098,7439,7788,8145,8510,8883,9264,9653,10050,10455,10868,11289,11718,12155,12600,13053,13514,13983,14460,14945,15438,15939,16448,16965,17490,18023,18564,19113,19670,20235,20808,21389,21978,22575,23180,23793,24414,25043,25680,26325,26978,27639,28308,28985,29670,30363,31064,31773,32490,33215,33948,34689,35438,36195,36960,37733,38514,39303,40100,40905,41718,42539,43368,44205,45050,45903,46764,47633,48510,49395,50288,51189,52098,53015,53940,54873,55814,56763,57720,58685,59658,60639,61628,62625,63630,64643,65664,66693,67730,68775,69828,70889,71958,73035,74120,75213,76314,77423,78540,79665,80798,81939,83088,84245,85410,86583,87764,88953,90150,91355,92568,93789,95018,96255,97500,98753,100014,101283,102560,103845,105138,106439,107748,109065,110390,111723,113064,114413,115770,117135,118508,119889,121278,122675,124080,125493,126914,128343,129780,131225,132678,134139,135608,137085,138570,140063,141564,143073,144590,146115,147648,149189,150738,152295,153860,155433,157014,158603,160200,161805,163418,165039,166668,168305,169950,171603,173264,174933,176610,178295,179988,181689,183398,185115,186840,188573,190314,192063,193820,195585,197358,199139,200928,202725,204530,206343,208164,209993,211830,213675,215528,217389,219258,221135,223020,224913,226814,228723,230640,232565,234498,236439,238388,240345,242310,244283,246264,248253 mov $1,$0 add $1,$0 pow $1,2 add $1,$0
198.75
1,520
0.818868
3bb40a4cd116f84f27c95d152215d13cd2358ece
27,330
html
HTML
vendor/Docs/index.html
georgedeath/TAsK
14c4abb3b3f9918accd59e9987e9403bd8a0470c
[ "MIT" ]
28
2015-03-05T04:12:58.000Z
2021-12-16T22:24:41.000Z
vendor/Docs/index.html
joshchea/TAsK
d66d0c7561e30b45308aabcf08f584326779f4ae
[ "MIT" ]
2
2017-02-07T15:37:37.000Z
2020-06-26T14:06:00.000Z
vendor/Docs/index.html
joshchea/TAsK
d66d0c7561e30b45308aabcf08f584326779f4ae
[ "MIT" ]
15
2015-07-09T11:53:16.000Z
2022-02-22T04:01:19.000Z
<!-- HTML header for doxygen 1.8.8--> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <!-- For Mobile Devices --> <meta name="viewport" content="width=device-width, initial-scale=1"> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <meta name="generator" content="Doxygen 1.8.9.1"/> <script type="text/javascript" src="https://code.jquery.com/jquery-2.1.1.min.js"></script> <title>Traffic Assignment frameworK (TAsK): Traffic Assignment frameworK (TAsK)</title> <!--<link href="tabs.css" rel="stylesheet" type="text/css"/>--> <script type="text/javascript" src="dynsections.js"></script> <link href="search/search.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="search/searchdata.js"></script> <script type="text/javascript" src="search/search.js"></script> <script type="text/javascript"> $(document).ready(function() { init_search(); }); </script> <link href="doxygen.css" rel="stylesheet" type="text/css" /> <link href="customdoxygen.css" rel="stylesheet" type="text/css"/> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.1/css/bootstrap.min.css"> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.1/js/bootstrap.min.js"></script> <script type="text/javascript" src="doxy-boot.js"></script> </head> <body> <nav class="navbar navbar-default" role="navigation"> <div class="container"> <div class="navbar-header"> <a class="navbar-brand">Traffic Assignment frameworK (TAsK) </a> </div> </div> </nav> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div class="content" id="content"> <div class="container"> <div class="row"> <div class="col-sm-12 panel panel-default" style="padding-bottom: 15px;"> <div style="margin-bottom: 15px;"> <!-- end header part --> <!-- Generated by Doxygen 1.8.9.1 --> <script type="text/javascript"> var searchBox = new SearchBox("searchBox", "search",false,'Search'); </script> <div id="navrow1" class="tabs"> <ul class="tablist"> <li class="current"><a href="index.html"><span>Main&#160;Page</span></a></li> <li><a href="pages.html"><span>Related&#160;Pages</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li><a href="annotated.html"><span>Classes</span></a></li> <li><a href="files.html"><span>Files</span></a></li> <li> <div id="MSearchBox" class="MSearchBoxInactive"> <span class="left"> <img id="MSearchSelect" src="search/mag_sel.png" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" alt=""/> <input type="text" id="MSearchField" value="Search" accesskey="S" onfocus="searchBox.OnSearchFieldFocus(true)" onblur="searchBox.OnSearchFieldFocus(false)" onkeyup="searchBox.OnSearchFieldChange(event)"/> </span><span class="right"> <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a> </span> </div> </li> </ul> </div> </div><!-- top --> <!-- window showing the filter options --> <div id="MSearchSelectWindow" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" onkeydown="return searchBox.OnSearchSelectKey(event)"> </div> <!-- iframe showing the search results (closed by default) --> <div id="MSearchResultsWindow"> <iframe src="javascript:void(0)" frameborder="0" name="MSearchResults" id="MSearchResults"> </iframe> </div> <div class="header"> <div class="headertitle"> <div class="title">Traffic Assignment frameworK (TAsK) </div> </div> </div><!--header--> <div class="contents"> <div class="textblock"><p>The TAsK software implements several algorithms for solving the deterministic static traffic assignment problem with fixed demands, see <a class="el" href="citelist.html#CITEREF_Sheffi1985">[19]</a>, and the non-additive traffic assignment problem, see <a class="el" href="citelist.html#CITEREF_Larsson2004">[14]</a>.</p> <p>All code is implemented in the C++ programming language. This is open-source software distributed under the MIT license.</p> <p>The software was tested only on the Ubuntu (12.10, 13.10 and 14.04) operating system.</p> <dl class="section author"><dt>Author</dt><dd><a href="http://www.des.auckland.ac.nz/people/o-perederieieva">Olga Perederieieva</a> </dd> <dd> <a href="https://github.com/Boshen">Boshen Chen</a> (A* star shortest path algorithm) </dd> <dd> Benoit Mulocher (bi-directional bi-objective label-setting algorithm)</dd></dl> <p><b>Contributors</b> </p> <ul> <li><a href="http://www.lancaster.ac.uk/lums/people/all/matthias-ehrgott/">Matthias Ehrgott</a></li> <li><a href="https://unidirectory.auckland.ac.nz/profile/a-raith">Andrea Raith</a></li> <li><a href="http://www.its.leeds.ac.uk/people/staff-profiles/judith-wang/">Judith Y.T. Wang</a></li> <li><a href="http://www.rsm.nl/people/marie-schmidt/">Marie Schmidt</a></li> </ul> <p>The style sheet for documentation comes from <a href="https://github.com/Velron/doxygen-bootstrapped">https://github.com/Velron/doxygen-bootstrapped</a>.</p> <dl class="section version"><dt>Version</dt><dd>1.0</dd></dl> <dl class="section copyright"><dt>Copyright</dt><dd>MIT license</dd></dl> <h2>How to cite</h2> <p>In a paper, please, cite the following reference:</p> <blockquote class="doxtable"> <p>Olga Perederieieva, Matthias Ehrgott, Andrea Raith, Judith Y.T. Wang, A framework for and empirical study of algorithms for traffic assignment, Computers &amp; Operations Research, Volume 54, February 2015, Pages 90-107, ISSN 0305-0548, <a href="http://dx.doi.org/10.1016/j.cor.2014.08.024">http://dx.doi.org/10.1016/j.cor.2014.08.024</a>. </p> </blockquote> <p>In code documentation, include a reference to this website.</p> <h2>Features</h2> <ul> <li>11 algorithms for additive traffic assignment that belong to link-, path- and bush-based methods, see <a class="el" href="citelist.html#CITEREF_Perederieieva2015">[18]</a>.</li> <li>2 algorithms for non-additive traffic assignment (path equilibration and gradient projection).</li> <li>2 equilibration strategies, see <a class="el" href="citelist.html#CITEREF_Perederieieva2015">[18]</a>.</li> <li>3 algorithms for finding a step size (bisection, Armijo-like rule and quadratic approximation).</li> <li>Various options for direction of descent.</li> <li>3 flow update strategies for path-based algorithms.</li> <li>Non-additive shortest path algorithm based on bi-objective label-setting with speed-up techniques that exploit the traffic assignment structure.</li> <li>Plain text and KML output of computation results.</li> </ul> <h2>Installation instructions</h2> <p>Requirements:</p><ul> <li>C++ compiler (the software was tested with gcc 4.8.2).</li> <li>Boost library that can be downloaded from <a href="http://www.boost.org/">http://www.boost.org/</a>.</li> </ul> <p>Instructions:</p><ul> <li>Download archive with source code.</li> <li>Unzip.</li> <li>Open terminal, go to the folder with source code (src/) and type: make.</li> </ul> <p>By default extended floating point precision is used (long double type). In order to use double type, comment line CPPFLAGS += -DUSE_EXTENDED_PRECISION in Makefile and recompile code if necessary by typing in terminal: make clean; make.</p> <dl class="section note"><dt>Note</dt><dd>If double type is used instead of long double, algorithms might fail to find highly precise solutions.</dd></dl> <h2>Documentation</h2> <p>API documentation can be found in Docs/html/index.html.</p> <h2>Usage</h2> <p>In order to run the TAsK software one should create a text file with various run parameters first.</p> <h3>Example data</h3> <p>The archive with source code includes the SiouxFalls data instance from <a href="http://www.bgu.ac.il/~bargera/tntp/">http://www.bgu.ac.il/~bargera/tntp/</a>. This instance can be used for research purposes only.</p> <h3>How to run</h3> <p>After compiling the source code, one can run it with one of the two included parameter files. Example parameter files are <a href="../../input.params">input.params</a> for conventional traffic assignment and <a href="../../inputNonAdd.params">inputNonAdd.params</a> for non-additive traffic assignment. Please, use these files as templates for creating other files with parameters. </p><dl class="section note"><dt>Note</dt><dd>If some of the fields are missing or invalid values are used, the program will terminate with an error message or failed assertion.</dd></dl> <dl class="section warning"><dt>Warning</dt><dd>All field names and possible values are case-sensitive.</dd></dl> <p>In order to run code with <a href="../../input.params">input.params</a>:</p><ul> <li>Open terminal and go to the folder with source code.</li> <li>Type in terminal: ./ta ../input.params.</li> </ul> <p>File <a href="../../input.params">input.params</a> allows to solve the additive traffic assignment problem with the Algorithm B (for details, see <a class="el" href="citelist.html#CITEREF_Dial_2006">[7]</a>) based on quadratic approximation for the SiouxFalls instance.</p> <p>File <a href="../../inputNonAdd.params">inputNonAdd.params</a> allows to solve the non-additive traffic assignment problem with the path equilibration algorithm (for details, see <a class="el" href="citelist.html#CITEREF_Florian1995">[8]</a>) based on Newton step for the SiouxFalls instance.</p> <h3>Parameter files</h3> <p>A parameter file must contain the following fields (supported comments <b></b>/<b></b>* for multiple line comments, <b></b>/<b></b>/ for one line comments):</p> <div class="fragment"><div class="line">&lt;NETWORK&gt;: {Data/SiouxFalls_tolls.txt}</div> </div><!-- fragment --><p> Path to file with network data</p> <div class="fragment"><div class="line">&lt;OD_MATRIX&gt;: {Data/SiouxFalls_trips.txt}</div> </div><!-- fragment --><p> Path to file with O-D matrix.</p> <div class="fragment"><div class="line">&lt;WRITE_RND_TOLLS_TO_FILE&gt;: {}</div> </div><!-- fragment --><p> This field is used for the non-additive traffic assignment model. If this field is not empty, then instead of tolls specified in file with network, random ones will be used. This field is ignored if additive traffic assignment problem is solved.</p> <div class="fragment"><div class="line">&lt;RND_TOLLS_PROBABILITY&gt;: {}</div> </div><!-- fragment --><p> Probability to assign tolls to links. This field is ignored if option &lt;WRITE_RND_TOLLS_TO_FILE&gt; has empty value.</p> <div class="fragment"><div class="line">&lt;RND_TOLLS_MAX_TOLL&gt;: {}</div> </div><!-- fragment --><p> Maximum value of toll for randomly generated tolls. This field is ignored if option &lt;WRITE_RND_TOLLS_TO_FILE&gt; has empty value.</p> <div class="fragment"><div class="line">&lt;INDIFF_CURVE_TYPE&gt;: {PiecewiseLinear}</div> </div><!-- fragment --><p> Type of scalarization function. This field is used for the non-additive traffic assignment model. This field is ignored if option &lt;INDIFF_CURVE&gt; has empty value.</p> <p>Possible values:</p><ul> <li>PiecewiseLinear.</li> <li>Linear.</li> <li>Convex.</li> <li>Concave.</li> </ul> <div class="fragment"><div class="line">&lt;INDIFF_CURVE&gt;: {Curves/SiouxFalls_tolls.curves} </div> </div><!-- fragment --><p> Path to file with scalarization functions. This field is used for the non-additive traffic assignment model. If this field is empty, then the problem is considered to be additive. If this field is set to RND_GEN, then piecewise-linear scalarization functions will be generated randomly.</p> <div class="fragment"><div class="line">&lt;MAX_NB_POINTS_PER_CURVE&gt;: {3}</div> </div><!-- fragment --><p> Maximum number of breakpoints per piecewise-linear function. This field is ignored if option &lt;INDIFF_CURVE&gt; has any value except {RND_GEN}.</p> <div class="fragment"><div class="line">&lt;NODES&gt;: {}</div> </div><!-- fragment --><p> Path to file with node coordinates. Specify this field if LaTeX output is necessary.</p> <div class="fragment"><div class="line">&lt;TIME_LIMIT&gt; : {20000}</div> </div><!-- fragment --><p> Time limit of algorithm execution in seconds.</p> <div class="fragment"><div class="line">&lt;ShPathAlgo&gt; : {LC}</div> </div><!-- fragment --><p> Shortest path algorithm. Possible values:</p><ul> <li>LC - single-source label-setting algorithm. If this option is chosen along with a path-based algorithm, then single-source label-setting will be used for point-to-point shortest path calculations which is much slower than A*. Works only for additive traffic assignment. If one tries to choose this option for non-additive traffic assignment, then the program will terminate with failed assertion.</li> <li>Astar - A* point-to-point algorithm. If this option is specified, A* will be used for path-based algorithms, and one-source Dijkstra's algorithm for convergence measure. If this option is specified along with a link- or bush-based algorithm, then for all one-source shortest path calculations Dijkstra's algorithm will be used. Works only for additive traffic assignment. If one tries to choose this option for non-additive traffic assignment, then the program will terminate with failed assertion. <dl class="section warning"><dt>Warning</dt><dd>Astar option does not work with TAPAS. Never use them together.</dd></dl> </li> <li>NonAdd - non-additive shortest path. Works only for non-additive traffic assignment. If one tries to choose this option for additive traffic assignment, then the program will terminate with failed assertion.</li> <li>LazyNonAdd - lazy non-additive shortest path, see <a class="el" href="citelist.html#CITEREF_Chen1998">[3]</a>. Works only for non-additive traffic assignment. If one tries to choose this option for additive traffic assignment, then the program will terminate with failed assertion.</li> <li>LazySP - lazy additive shortest path, see <a class="el" href="citelist.html#CITEREF_Chen1998">[3]</a>. Works only for additive traffic assignment. If one tries to choose this option for non-additive traffic assignment, then the program will terminate with failed assertion.</li> </ul> <div class="fragment"><div class="line">&lt;UseP2PShPathWithRandomReturn&gt;: {} </div> </div><!-- fragment --><p> If any non-empty value is specified, then the randomised flow update strategy is used where probability of calculating a point-to-point shortest path depends on the iteration number. This option works only with path-based algorithms and is ignored if an algorithm from a different group is used.</p> <div class="fragment"><div class="line">&lt;FIXED_PROBABILITY&gt;: {}</div> </div><!-- fragment --><p> Probability of calculating a point-to-point shortest path. Possible values: any real number in the interval (0, 1]. This option is ignored if field &lt;UseP2PShPathWithRandomReturn&gt; has empty value.</p> <div class="fragment"><div class="line">&lt;CONV_MEASURE&gt;: {MAX_DIFF} </div> </div><!-- fragment --><p> Convergence measure. Possible values:</p><ul> <li>RGAP - relative gap. This option works for additive traffic assignment only.</li> <li>MAX_DIFF - max-min cost difference bound, see <a class="el" href="citelist.html#CITEREF_Dial_2006">[7]</a>. This option works for path-based algorithms only (for both additive and non-additive problems).</li> </ul> <div class="fragment"><div class="line">&lt;PRECISION&gt;: {1e-5}</div> </div><!-- fragment --><p> Algorithm precision. For example, if &lt;PRECISION&gt;: {1e-5}, then the algorithm will terminate when convergence measure reaches any value strictly smaller than 1e-5. Possible values: any positive number.</p> <div class="fragment"><div class="line">&lt;ZERO_FLOW&gt;: {1e-10}</div> </div><!-- fragment --><p> Link flow tolerance. For example, if &lt;ZERO_FLOW&gt;: {1e-10}, then link flow will be reset to zero if its value is less than or equal to 1e-10. Possible values: any positive number.</p> <div class="fragment"><div class="line">&lt;DIR_TOLERANCE&gt;: {1e-10}</div> </div><!-- fragment --><p> Tolerance of descent direction of path- and bush-based algorithms. For example, if &lt;DIR_TOLERANCE&gt;: {1e-10}, then a component of the direction of descent is set to zero if its value is less than 1e-10. Possible values: any positive number.</p> <div class="fragment"><div class="line">&lt;ALGORITHM&gt;: {PE}</div> </div><!-- fragment --><p> Algorithm. Possible values:</p><ul> <li>FW - Frank-Wolfe, see <a class="el" href="citelist.html#CITEREF_Frank1956">[10]</a>.</li> <li>CFW - conjugate Frank-Wolfe, see <a class="el" href="citelist.html#CITEREF_Mitradjieva2013">[16]</a>.</li> <li>BFW - bi-conjugate Frank-Wolfe, see <a class="el" href="citelist.html#CITEREF_Mitradjieva2013">[16]</a>.</li> <li>PE - path equilibration, see <a class="el" href="citelist.html#CITEREF_Dafermos1968">[4]</a> and <a class="el" href="citelist.html#CITEREF_Florian1995">[8]</a>.</li> <li>GP - gradient projection, see <a class="el" href="citelist.html#CITEREF_Jayakrishnan1994">[12]</a> and <a class="el" href="citelist.html#CITEREF_Chen1998">[3]</a>.</li> <li>PG - projected gradient, see <a class="el" href="citelist.html#CITEREF_MichaelFlorian2009">[9]</a>.</li> <li>ISP - improved social pressure, see <a class="el" href="citelist.html#CITEREF_Kumar2011">[13]</a>.</li> <li>B - Algorithm B based on Newton step, see <a class="el" href="citelist.html#CITEREF_Dial_2006">[7]</a> and <a class="el" href="citelist.html#CITEREF_Boyles2011">[2]</a>.</li> <li>Bstep - Algorithm B based on a line search, see <a class="el" href="citelist.html#CITEREF_Dial_2006">[7]</a> and <a class="el" href="citelist.html#CITEREF_Boyles2011">[2]</a>.</li> <li>LUCE - linear user cost equilibrium, see <a class="el" href="citelist.html#CITEREF_Gentile2014">[11]</a>.</li> <li>TAPAS - traffic assignment by paired alternative segments based on Newton step, see <a class="el" href="citelist.html#CITEREF_Hillel2010">[1]</a>.</li> <li>TAPASstep - traffic assignment by paired alternative segments based on a line search, see <a class="el" href="citelist.html#CITEREF_Hillel2010">[1]</a>.</li> </ul> <dl class="section warning"><dt>Warning</dt><dd>In the case of non-additive traffic assignment only the PE and GP options are available with &lt;APPROACH&gt; set to {APP3}.</dd></dl> <div class="fragment"><div class="line">&lt;LINE_SEARCH&gt;: {BISEC}.</div> </div><!-- fragment --><p> Line search. This field is used only for algorithms based on line search. If a different algorithm is specified, this field is ignored. Possible values:</p><ul> <li>BISEC - bisection.</li> <li>ARMIJO - Armijo-like rule.</li> <li>QUAD_APP - quadratic approximation.</li> </ul> <div class="fragment"><div class="line">&lt;LS_PRECISION&gt;: {1e-15}</div> </div><!-- fragment --><p> Line search tolerance. This field is used only if one of the line search methods is used.</p> <div class="fragment"><div class="line">&lt;ARMIJO_DEC&gt;: {2}</div> </div><!-- fragment --><p> Decrement in Armijo-like rule. This option is applicable only if &lt;LINE_SEARCH&gt;: {ARMIJO}.</p> <div class="fragment"><div class="line">&lt;EQUILIBRATION&gt;: {EQI}</div> </div><!-- fragment --><p> Type of equilibration. Possible values:</p><ul> <li>EQI - Equilibration I, see <a class="el" href="citelist.html#CITEREF_Perederieieva2015">[18]</a>.</li> <li>EQII - Equilibration II, see <a class="el" href="citelist.html#CITEREF_Perederieieva2015">[18]</a>.</li> </ul> <div class="fragment"><div class="line">&lt;MAX_ITER&gt;: {10}</div> </div><!-- fragment --><p> Maximum number of iterations for Equilibration II.</p> <div class="fragment"><div class="line">&lt;APPROACH&gt;: {APP3}</div> </div><!-- fragment --><p> Type of the direction of descent for path-based algorithms. Possible values depend on the algorithm.</p><ul> <li>For PE:<ul> <li>APP1 - path equilibration based on a line search.</li> <li>APP3 - path equilibration based on Newton step.</li> </ul> </li> <li>For GP:<ul> <li>APP1 - gradient projection based on a line search.</li> <li>APP2 - gradient projection based on a line search with scaled direction of descent.</li> <li>APP3 - gradient projection without a line search.</li> </ul> </li> <li>For PG:<ul> <li>APP1 - projected gradient based on a line search.</li> </ul> </li> <li>For ISP:<ul> <li>APP1 - improved social pressure based on a line search.</li> </ul> </li> </ul> <div class="fragment"><div class="line">&lt;ALPHA&gt;: {0.25}</div> </div><!-- fragment --><p> Constant that is used in gradient projection without a line search, see <a class="el" href="citelist.html#CITEREF_Jayakrishnan1994">[12]</a>. Valid values: any positive real number. This value must be set to a positive number even if gradient projection is not used.</p> <div class="fragment"><div class="line">&lt;SLOPE&gt;: {1e-15}</div> </div><!-- fragment --><p> Minimum slope of the derivative of link cost function used in improved social pressure. This value must be set to a positive number even if improved social pressure is not used.</p> <div class="fragment"><div class="line">&lt;ISP_SCALE&gt;: {0.15}</div> </div><!-- fragment --><p> The parameter of the improved social pressure algorithm that is used to divide all paths into two sets, for details see <a class="el" href="citelist.html#CITEREF_Kumar2011">[13]</a>. This value must be set to a positive number even if improved social pressure is not used.</p> <div class="fragment"><div class="line">&lt;NEWTON_STEPS&gt;: {SINGLE}</div> </div><!-- fragment --><p> Type of Newton step for Algorithm B and TAPAS. Possible values:</p><ul> <li>SINGLE - performs one Newton step.</li> <li>MULTI - performs several Newton steps.</li> </ul> <div class="fragment"><div class="line">&lt;MU&gt;: {0.5}</div> </div><!-- fragment --><p> Constant used in TAPAS for determining cost-effective PAS.</p> <div class="fragment"><div class="line">&lt;V&gt;: {0.25}</div> </div><!-- fragment --><p> Constant used in TAPAS for determining flow-effective PAS.</p> <div class="fragment"><div class="line">&lt;BIOBJ_SHPATH_P2P&gt;: {BiLabelSetting} </div> </div><!-- fragment --><p> Bi-objective point-to-point shortest path algorithm. This field is used on for non-additive traffic assignment. Possible values:</p><ul> <li>BiLabelSetting - bi-objective label-setting.</li> <li>BiLabelSetting_bidirectional - bi-directional bi-objective label-setting.</li> </ul> <div class="fragment"><div class="line">&lt;BLS_BOUNDS&gt; : {zeroFlow}</div> </div><!-- fragment --><p> Travel time lower bound. This field is used only for non-additive traffic assignment. If empty, then no bounds are used, otherwise possible values:</p><ul> <li>zeroFlow - travel time bounds based on zero flows.</li> <li>currentFlow - travel time bounds based on current flows.</li> </ul> <div class="fragment"><div class="line">&lt;USE_EXISTING_PATHS&gt; : {onePath}</div> </div><!-- fragment --><p> Addition of known paths technique. This field is used only for non-additive traffic assignment. If empty no paths are added, otherwise possible values are:</p><ul> <li>onePath - only shortest path is added.</li> <li>currentPaths - all existing paths are added.</li> </ul> <div class="fragment"><div class="line">&lt;USE_PATH_COST_DOMINATION&gt; : {yes}</div> </div><!-- fragment --><p> Path cost domination rule. This field is used only for non-additive traffic assignment. If empty usual domination rule is used, otherwise domination by path cost is used.</p> <div class="fragment"><div class="line">&lt;SHOW_CONVERGENCE&gt;: {yes}</div> </div><!-- fragment --><p> If the value of this field is not empty, prints convergence on the screen.</p> <div class="fragment"><div class="line">&lt;LINK_FLOWS&gt;: {}</div> </div><!-- fragment --><p> Path to file where link flows must be written. If the field is empty, no file will be created. If the field is set to AUTO, an automatically generated name will be used.</p> <div class="fragment"><div class="line">&lt;CONVERGENCE&gt;: {}</div> </div><!-- fragment --><p> Path to file where convergence must be written. If the field is empty, no file will be created. If the field is set to AUTO, an automatically generated name will be used.</p> <div class="fragment"><div class="line">&lt;PATH_SET&gt;: {}</div> </div><!-- fragment --><p> Path to file where path sets must be written. Applicable only to path-based algorithms. If the field is empty, no file will be created. If the field is set to AUTO, an automatically generated name will be used.</p> <div class="fragment"><div class="line">&lt;LATEX_OUTPUT&gt;: {net.tex}</div> </div><!-- fragment --><p>Path to file where latex output must be written. If this field is specified, then field &lt;NODES&gt; must be specified too. If the field is empty, no file will be created. If the field is set to AUTO, an automatically generated name will be used.</p> <dl class="section note"><dt>Note</dt><dd>For KML output one has to modify main.cpp and use classes <a class="el" href="classKMLNetOutput.html" title="KML for network performance analysis (colour-coded based on the ratio flow/capacity) ...">KMLNetOutput</a>, <a class="el" href="classKMLSelectLink.html" title="Implements creation of kml-files for select link analysis. ">KMLSelectLink</a>, <a class="el" href="classKMLPlotTolls.html" title="This class creates kml-file where tolled links are highlighted in red. ">KMLPlotTolls</a> and <a class="el" href="classDiffKMLNetOutput.html" title="This class implements KML files that describe link flow differences between solutions (usually two so...">DiffKMLNetOutput</a>.</dd></dl> <h2>Existing problems of the current implementation</h2> <ul> <li>Excessive usage of pointers where references are more appropriate.</li> <li>In a few places arrays are used where vectors would be better.</li> <li><a class="el" href="classObjectManager.html" title="This class is responsible for creation of all objects. ">ObjectManager</a> is responsible for creation of ALL objects.</li> <li><a class="el" href="classStarNetwork.html" title="This class implements forward star graph representation. ">StarNetwork</a> and <a class="el" href="classPathBasedFlowMove.html" title="This class is responsible for performing a flow move within current ODSet. ">PathBasedFlowMove</a> iterator-like methods are not safe to use in nested loops. </li> </ul> </div></div><!-- contents --> <!-- HTML footer for doxygen 1.8.8--> <!-- start footer part --> </div> </div> </div> </div> </div> <hr class="footer"/><address class="footer"><small> Generated on Tue Mar 10 2015 15:45:17 for Traffic Assignment frameworK (TAsK) by &#160;<a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/> </a> 1.8.9.1 </small></address> </body> </html>
84.351852
728
0.709843
f99a3e3c7d7abe2b38dc1b98a0ffd8cdbcebfa2e
3,742
swift
Swift
Grapevine/View/NewPost.swift
Jerryx2020/Grapevine
26f71fe9d9ccc118274a628b8aab7c31530289cd
[ "Apache-2.0", "Unlicense" ]
1
2021-05-21T22:53:01.000Z
2021-05-21T22:53:01.000Z
Grapevine/View/NewPost.swift
Jerryx2020/Grapevine
26f71fe9d9ccc118274a628b8aab7c31530289cd
[ "Apache-2.0", "Unlicense" ]
null
null
null
Grapevine/View/NewPost.swift
Jerryx2020/Grapevine
26f71fe9d9ccc118274a628b8aab7c31530289cd
[ "Apache-2.0", "Unlicense" ]
2
2021-06-11T19:55:19.000Z
2021-06-11T20:00:52.000Z
// // NewPost.swift // Grapevine // // Created by Jerry Xia on 3/15/21. // import SwiftUI struct NewPost: View { // Defines the view that appears when creating a new post @StateObject var newPostData = NewPostModel() @Environment(\.presentationMode) var present @Binding var updateId : String var body: some View { VStack{ HStack(spacing: 15) { Button(action: { self.updateId = "" present.wrappedValue.dismiss() }) { Text("Cancel") .fontWeight(.bold) .foregroundColor(Color("blue")) } Spacer(minLength: 0) if updateId == "" { // Only For New Posts.... Button(action: {newPostData.picker.toggle()}) { Image(systemName: "photo.fill") .font(.title) .foregroundColor(Color("blue")) } } Button(action: {newPostData.post(updateId: updateId,present: present)}) { Text("Post") .fontWeight(.bold) .foregroundColor(.white) .padding(.vertical,10) .padding(.horizontal,25) .background(Color("blue")) .clipShape(Capsule()) } .disabled(newPostData.postTxt == "" ? true : false) // Ensures that the post contains data .opacity(newPostData.postTxt == "" ? 0.5 : 1) // Creates visual effect that echoes the above sentiment } .padding() .opacity(newPostData.isPosting ? 0.5 : 1) .disabled(newPostData.isPosting ? true : false) TextEditor(text: $newPostData.postTxt) .cornerRadius(15) .padding() .opacity(newPostData.isPosting ? 0.5 : 1) .disabled(newPostData.isPosting ? true : false) // Dispalying Image if its selected... if newPostData.img_Data.count != 0 { ZStack(alignment: Alignment(horizontal: .trailing, vertical: .top)) { Image(uiImage: UIImage(data: newPostData.img_Data)!) .resizable() .aspectRatio(contentMode: .fill) .frame(width: UIScreen.main.bounds.width / 2, height: 150) .cornerRadius(15) // Cancel Button... Button(action: {newPostData.img_Data = Data(count: 0)}) { Image(systemName: "xmark") .foregroundColor(.white) .padding(10) .background(Color("blue")) .clipShape(Circle()) } } .padding() .opacity(newPostData.isPosting ? 0.5 : 1) .disabled(newPostData.isPosting ? true : false) } } .background(Color("bg").ignoresSafeArea(.all, edges: .all)) .sheet(isPresented: $newPostData.picker) { ImagePicker(picker: $newPostData.picker, img_Data: $newPostData.img_Data) } } }
36.330097
118
0.421432
317d48b8fc1d660a76dc3b598dd76ba0157d2a33
4,855
swift
Swift
Example/AAMultiSelectController-Swift/AAMultiSelectController-Swift/AAViewController.swift
skhye05/AAMultiSelectController
96dc0dcde90a0ff1f2fa4b3c1b622309f00c63f4
[ "MIT" ]
null
null
null
Example/AAMultiSelectController-Swift/AAMultiSelectController-Swift/AAViewController.swift
skhye05/AAMultiSelectController
96dc0dcde90a0ff1f2fa4b3c1b622309f00c63f4
[ "MIT" ]
null
null
null
Example/AAMultiSelectController-Swift/AAMultiSelectController-Swift/AAViewController.swift
skhye05/AAMultiSelectController
96dc0dcde90a0ff1f2fa4b3c1b622309f00c63f4
[ "MIT" ]
null
null
null
// // AAViewController.swift // AAMultiSelectController-Swift // // Created by dev-aozhimin on 17/2/20. // Copyright © 2017年 aozhimin. All rights reserved. // import UIKit private struct TableViewRow { static let AATableViewCellTypeNone: Int = 0 static let AATableViewCellTypeFadeIn: Int = 1 static let AATableViewCellTypeGrowIn: Int = 2 static let AATableViewCellTypeShrinkIn: Int = 3 static let AATableViewCellTypeSlideInFromTop: Int = 4 static let AATableViewCellTypeSlideInFromBottom: Int = 5 static let AATableViewCellTypeSlideInFromLeft: Int = 6 static let AATableViewCellTypeSlideInFromRight: Int = 7 static let AATableViewCellTypeBounceIn: Int = 8 static let AATableViewCellTypeBounceInFromTop: Int = 9 static let AATableViewCellTypeBounceInFromBottom: Int = 10 static let AATableViewCellTypeBounceInFromLeft: Int = 11 static let AATableViewCellTypeBounceInFromRight: Int = 12 } private let TableRowTitles: [Int : String] = [ TableViewRow.AATableViewCellTypeNone : "None", TableViewRow.AATableViewCellTypeFadeIn : "FadeIn", TableViewRow.AATableViewCellTypeGrowIn : "GrowIn", TableViewRow.AATableViewCellTypeShrinkIn : "ShrinkIn", TableViewRow.AATableViewCellTypeSlideInFromTop : "SlideInFromTop", TableViewRow.AATableViewCellTypeSlideInFromBottom : "SlideInFromBottom", TableViewRow.AATableViewCellTypeSlideInFromLeft : "SlideInFromLeft", TableViewRow.AATableViewCellTypeSlideInFromRight : "SlideInFromRight", TableViewRow.AATableViewCellTypeBounceIn : "BounceIn", TableViewRow.AATableViewCellTypeBounceInFromTop : "BounceInFromTop", TableViewRow.AATableViewCellTypeBounceInFromBottom : "BounceInFromBottom", TableViewRow.AATableViewCellTypeBounceInFromLeft : "BounceInFromLeft", TableViewRow.AATableViewCellTypeBounceInFromRight : "BounceInFromRight" ] private let OrderTypeDescription = [ "Objective-C", "Swift", "Java", "Python", "PHP", "Ruby", "JavaScript", "Go", "Erlang", "C", "C++", "C#", ] private let kTableViewRowIdentifier: String = "tableViewCellIdentifier" private let kMultiSelectViewHeight: CGFloat = 250 private let kMultiSelectViewWidthRatio: CGFloat = 0.8 public class AAViewController: UIViewController, UITableViewDataSource, UITableViewDelegate { private var dataArray:[AAMultiSelectModel]! { get { var data:[AAMultiSelectModel] = [] for (index, element) in OrderTypeDescription.enumerate() { let model = AAMultiSelectModel.init() model.title = element model.multiSelectId = index data.append(model) } return data } } private lazy var multiSelectVC: AAMultiSelectViewController = { var vc = AAMultiSelectViewController.init() vc.titleText = "Please select a language" vc.view.frame = CGRectMake(0, 0, CGRectGetWidth(self.view.frame) * kMultiSelectViewWidthRatio, kMultiSelectViewHeight) vc.itemTitleColor = UIColor.redColor() vc.dataArray = self.dataArray vc.confirmBlock = { selectedObjects in var message = "You chose:" for obj in selectedObjects as! [AAMultiSelectModel] { message += "\(obj.title)," } let alertView: UIAlertView = UIAlertView.init(title: "", message: message, delegate: nil, cancelButtonTitle: "cancel", otherButtonTitles: "confirm") alertView.show() } return vc }() public override func viewDidLoad() { super.viewDidLoad() title = "AAMultiSelectController-Swift" } // MARK: UITableViewDelegate & UITableViewDataSource public func tableView(tableView: UITableView, numberOfRowsInSection section: Int) -> Int { return TableRowTitles.count } public func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell { let cell = tableView.dequeueReusableCellWithIdentifier(kTableViewRowIdentifier) as UITableViewCell! cell.textLabel?.text = TableRowTitles[indexPath.row] return cell } public func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath) { tableView.deselectRowAtIndexPath(indexPath, animated: true) self.multiSelectVC.popupShowType = AAPopupViewShowType(rawValue: indexPath.row)! self.multiSelectVC.popupDismissType = AAPopupViewDismissType(rawValue: indexPath.row)! self.multiSelectVC.show() } }
40.458333
160
0.675798
d3ffa3b85d3b5e772a647ee1572f93452b56fd93
349
sql
SQL
sql/InitTable_npc.sql
cuongdt1994/v204.1
9b0e2d05bcb6d6c1cf2341a93267aa1b8c4bf7a5
[ "MIT" ]
9
2021-04-26T11:59:29.000Z
2021-12-20T13:15:27.000Z
sql/InitTable_npc.sql
varenty-x/v203.4
359d6575ef8256bb2d6df87bf4156c4608243232
[ "MIT" ]
null
null
null
sql/InitTable_npc.sql
varenty-x/v203.4
359d6575ef8256bb2d6df87bf4156c4608243232
[ "MIT" ]
6
2021-07-14T06:32:05.000Z
2022-02-06T02:32:56.000Z
CREATE TABLE `npc` ( `id` int(11) NOT NULL AUTO_INCREMENT, `npcid` int(11) DEFAULT NULL, `mapid` int(11) DEFAULT NULL, `x` int(11) DEFAULT NULL, `y` int(11) DEFAULT NULL, `cy` int(11) DEFAULT NULL, `rx0` int(11) DEFAULT NULL, `rx1` int(11) DEFAULT NULL, `fh` int(11) DEFAULT NULL, PRIMARY KEY (`id`) ) AUTO_INCREMENT=3
29.083333
40
0.627507
c2cbeea3e76c01e3f852d9993b411fc637e1a10a
575
go
Go
options.go
extoor/traefik-forward-auth
1f95a6cac063bdda8f007f0639475da8e0d4d8d4
[ "MIT" ]
null
null
null
options.go
extoor/traefik-forward-auth
1f95a6cac063bdda8f007f0639475da8e0d4d8d4
[ "MIT" ]
null
null
null
options.go
extoor/traefik-forward-auth
1f95a6cac063bdda8f007f0639475da8e0d4d8d4
[ "MIT" ]
null
null
null
package main import ( "encoding/base64" ) func addPadding(secret string) string { l := len(secret) if l > 32 { return secret[0:32] } padding := l % 4 switch padding { case 1: return secret + "===" case 2: return secret + "==" case 3: return secret + "=" default: return secret } } // secretBytes attempts to base64 decode the secret, if that fails it treats the secret as binary func secretBytes(secret string) []byte { b, err := base64.URLEncoding.DecodeString(secret) if err == nil { secret = string(b) } return []byte(addPadding(secret)) }
16.428571
97
0.66087
51544e1c7345f4d3acd2208a991096e05db2a0ee
7,022
asm
Assembly
Transynther/x86/_processed/NONE/_xt_/i9-9900K_12_0xca_notsx.log_21829_498.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
9
2020-08-13T19:41:58.000Z
2022-03-30T12:22:51.000Z
Transynther/x86/_processed/NONE/_xt_/i9-9900K_12_0xca_notsx.log_21829_498.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
1
2021-04-29T06:29:35.000Z
2021-05-13T21:02:30.000Z
Transynther/x86/_processed/NONE/_xt_/i9-9900K_12_0xca_notsx.log_21829_498.asm
ljhsiun2/medusa
67d769b8a2fb42c538f10287abaf0e6dbb463f0c
[ "MIT" ]
3
2020-07-14T17:07:07.000Z
2022-03-21T01:12:22.000Z
.global s_prepare_buffers s_prepare_buffers: push %r12 push %r14 push %r15 push %r9 push %rbx push %rcx push %rdi push %rsi lea addresses_D_ht+0x3aeb, %rsi lea addresses_UC_ht+0x10392, %rdi nop nop nop add %rbx, %rbx mov $105, %rcx rep movsb add %rsi, %rsi lea addresses_A_ht+0x50c6, %r14 clflush (%r14) nop nop nop sub $42277, %r9 mov $0x6162636465666768, %rsi movq %rsi, (%r14) nop and %rdi, %rdi lea addresses_D_ht+0x110a, %rsi lea addresses_WT_ht+0x16e92, %rdi clflush (%rdi) nop sub $52499, %r12 mov $0, %rcx rep movsw add %r9, %r9 lea addresses_WT_ht+0xb792, %rsi lea addresses_WC_ht+0x12392, %rdi nop nop cmp $56478, %r14 mov $26, %rcx rep movsw nop nop nop and %rsi, %rsi lea addresses_D_ht+0xa75a, %r9 nop dec %rbx mov (%r9), %si nop xor $54517, %r12 lea addresses_A_ht+0x17392, %rsi nop nop nop cmp %rbx, %rbx mov (%rsi), %ecx nop inc %rbx lea addresses_WC_ht+0xe432, %rsi lea addresses_D_ht+0x1a9b2, %rdi nop nop nop nop nop sub %r9, %r9 mov $115, %rcx rep movsw nop xor %rsi, %rsi lea addresses_D_ht+0x1b7b2, %r9 nop nop dec %r12 mov (%r9), %rsi nop inc %r14 lea addresses_A_ht+0x7a52, %r12 nop nop add %rdi, %rdi mov $0x6162636465666768, %rsi movq %rsi, %xmm4 and $0xffffffffffffffc0, %r12 movntdq %xmm4, (%r12) and %rcx, %rcx lea addresses_WT_ht+0x4adc, %rdi nop nop xor $55695, %r12 mov $0x6162636465666768, %rcx movq %rcx, %xmm1 and $0xffffffffffffffc0, %rdi movntdq %xmm1, (%rdi) nop nop add $47377, %r12 lea addresses_normal_ht+0xa792, %rsi lea addresses_normal_ht+0x1b496, %rdi add $44296, %r15 mov $73, %rcx rep movsb sub %rsi, %rsi lea addresses_WT_ht+0x9912, %rdi clflush (%rdi) nop sub %rsi, %rsi movb (%rdi), %r15b nop nop and $5738, %r14 pop %rsi pop %rdi pop %rcx pop %rbx pop %r9 pop %r15 pop %r14 pop %r12 ret .global s_faulty_load s_faulty_load: push %r10 push %r12 push %r14 push %rax push %rbx push %rdi // Faulty Load lea addresses_normal+0x14792, %rdi nop nop nop xor %rbx, %rbx movb (%rdi), %r14b lea oracles, %r12 and $0xff, %r14 shlq $12, %r14 mov (%r12,%r14,1), %r14 pop %rdi pop %rbx pop %rax pop %r14 pop %r12 pop %r10 ret /* <gen_faulty_load> [REF] {'OP': 'LOAD', 'src': {'same': False, 'type': 'addresses_normal', 'NT': False, 'AVXalign': False, 'size': 4, 'congruent': 0}} [Faulty Load] {'OP': 'LOAD', 'src': {'same': True, 'type': 'addresses_normal', 'NT': False, 'AVXalign': False, 'size': 1, 'congruent': 0}} <gen_prepare_buffer> {'OP': 'REPM', 'src': {'same': False, 'congruent': 0, 'type': 'addresses_D_ht'}, 'dst': {'same': True, 'congruent': 10, 'type': 'addresses_UC_ht'}} {'OP': 'STOR', 'dst': {'same': False, 'type': 'addresses_A_ht', 'NT': False, 'AVXalign': False, 'size': 8, 'congruent': 2}} {'OP': 'REPM', 'src': {'same': False, 'congruent': 3, 'type': 'addresses_D_ht'}, 'dst': {'same': False, 'congruent': 1, 'type': 'addresses_WT_ht'}} {'OP': 'REPM', 'src': {'same': False, 'congruent': 11, 'type': 'addresses_WT_ht'}, 'dst': {'same': False, 'congruent': 8, 'type': 'addresses_WC_ht'}} {'OP': 'LOAD', 'src': {'same': False, 'type': 'addresses_D_ht', 'NT': False, 'AVXalign': False, 'size': 2, 'congruent': 2}} {'OP': 'LOAD', 'src': {'same': False, 'type': 'addresses_A_ht', 'NT': False, 'AVXalign': False, 'size': 4, 'congruent': 10}} {'OP': 'REPM', 'src': {'same': False, 'congruent': 5, 'type': 'addresses_WC_ht'}, 'dst': {'same': False, 'congruent': 2, 'type': 'addresses_D_ht'}} {'OP': 'LOAD', 'src': {'same': False, 'type': 'addresses_D_ht', 'NT': False, 'AVXalign': False, 'size': 8, 'congruent': 4}} {'OP': 'STOR', 'dst': {'same': False, 'type': 'addresses_A_ht', 'NT': True, 'AVXalign': False, 'size': 16, 'congruent': 6}} {'OP': 'STOR', 'dst': {'same': False, 'type': 'addresses_WT_ht', 'NT': True, 'AVXalign': False, 'size': 16, 'congruent': 1}} {'OP': 'REPM', 'src': {'same': False, 'congruent': 11, 'type': 'addresses_normal_ht'}, 'dst': {'same': False, 'congruent': 2, 'type': 'addresses_normal_ht'}} {'OP': 'LOAD', 'src': {'same': False, 'type': 'addresses_WT_ht', 'NT': False, 'AVXalign': False, 'size': 1, 'congruent': 7}} {'34': 21829} 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 34 */
39.897727
2,999
0.659499
472b384a174107eaf94d2ac6753bcf6534aecb8f
3,971
swift
Swift
Instagram/View/EditProfileCell/EditProfileCell.swift
unioan/Instagram
821a7b5c7c3580a3e25d09cec510cf51b98e83c3
[ "MIT" ]
null
null
null
Instagram/View/EditProfileCell/EditProfileCell.swift
unioan/Instagram
821a7b5c7c3580a3e25d09cec510cf51b98e83c3
[ "MIT" ]
null
null
null
Instagram/View/EditProfileCell/EditProfileCell.swift
unioan/Instagram
821a7b5c7c3580a3e25d09cec510cf51b98e83c3
[ "MIT" ]
null
null
null
// // EditProfileCell.swift // Instagram // // Created by Владимир Юшков on 27.01.2022. // import UIKit protocol EditProfileCellDelegat: AnyObject { func handleTextFieldsChanges(fullnameTF: String?, usernameTF: String?) func setTextFieldDelegates(for fullnameTF: UITextField, and usernameTF: UITextField) } class EditProfileCell: UICollectionViewCell { static let identifier = "EditProfileCell" var editCellViewModel: EditProfileModel? { didSet { configure() } } weak var delegat: EditProfileCellDelegat? //MARK: Properties private let nameLabel: UILabel = { let label = UILabel() label.font = UIFont.boldSystemFont(ofSize: 14) label.text = "Name" return label }() private let usernameLabel: UILabel = { let label = UILabel() label.font = UIFont.boldSystemFont(ofSize: 14) label.text = "Username" return label }() private let fullNameTextField: UITextField = { let tf = UITextField() tf.placeholder = "Full name goes here..." tf.addTarget(self, action: #selector(textFieldInputChanged), for: .editingChanged) return tf }() private let usernameTextField: UITextField = { let tf = UITextField() tf.placeholder = "Username goes here..." tf.addTarget(self, action: #selector(textFieldInputChanged), for: .editingChanged) return tf }() //MARK: Actions @objc func textFieldInputChanged() { let fullnameTF = fullNameTextField.text let usernameTF = usernameTextField.text?.lowercased() usernameTextField.text = usernameTF // Не позволяет писать заглавными буквами delegat?.handleTextFieldsChanges(fullnameTF: fullnameTF, usernameTF: usernameTF) delegat?.setTextFieldDelegates(for: fullNameTextField, and: usernameTextField) } //MARK: Life Cycle override init(frame: CGRect) { super.init(frame: frame) backgroundColor = .white addSubview(nameLabel) nameLabel.setDimensions(height: 40, width: 100) nameLabel.anchor(top: topAnchor, left: leftAnchor, paddingLeft: 8) addSubview(usernameLabel) usernameLabel.setDimensions(height: 40, width: 100) usernameLabel.anchor(top: nameLabel.bottomAnchor, left: leftAnchor, paddingTop: 8, paddingLeft: 8) contentView.addSubview(fullNameTextField) fullNameTextField.setHeight(40) fullNameTextField.anchor(top: topAnchor, left: nameLabel.rightAnchor, right: rightAnchor, paddingLeft: 8, paddingRight: 8) contentView.addSubview(usernameTextField) usernameTextField.setHeight(40) usernameTextField.anchor(top: fullNameTextField.bottomAnchor, left: usernameLabel.rightAnchor, right: rightAnchor, paddingTop: 8, paddingLeft: 8, paddingRight: 8) let fulnameDivider = UIView() fulnameDivider.backgroundColor = .lightGray addSubview(fulnameDivider) fulnameDivider.anchor(top: fullNameTextField.bottomAnchor, left: fullNameTextField.leftAnchor, right: rightAnchor, paddingTop: 4, height: 0.5) let usernameDivider = UIView() usernameDivider.backgroundColor = .lightGray addSubview(usernameDivider) usernameDivider.anchor(top: usernameTextField.bottomAnchor, left: usernameTextField.leftAnchor, right: rightAnchor, paddingTop: 4, height: 0.5) } //MARK: Helpers func configure() { guard let viewModel = editCellViewModel else { return } fullNameTextField.text = viewModel.fullname usernameTextField.text = viewModel.username } required init?(coder: NSCoder) { fatalError("init(coder:) has not been implemented") } }
33.652542
151
0.650214
049bac82eeaaa8c33b206245a923043af6f667da
79
java
Java
2017/src/main/java/ie/tomlennon/aoc/day2/Vehicle.java
thomaslennon/AdventOfCode
83494ff88a193eb4c35a3b792ce3a74eab659928
[ "MIT" ]
null
null
null
2017/src/main/java/ie/tomlennon/aoc/day2/Vehicle.java
thomaslennon/AdventOfCode
83494ff88a193eb4c35a3b792ce3a74eab659928
[ "MIT" ]
null
null
null
2017/src/main/java/ie/tomlennon/aoc/day2/Vehicle.java
thomaslennon/AdventOfCode
83494ff88a193eb4c35a3b792ce3a74eab659928
[ "MIT" ]
null
null
null
package ie.tomlennon.aoc.day2; public interface Vehicle { void start(); }
13.166667
30
0.708861
05c6e8f3212ff24a0b1e8d5ec2a0da0ee07d6189
23,628
html
HTML
main.html
kmaraj/kmaraj
973bd4392607028afc52e502020bb8f26cc3e1a4
[ "MIT" ]
null
null
null
main.html
kmaraj/kmaraj
973bd4392607028afc52e502020bb8f26cc3e1a4
[ "MIT" ]
null
null
null
main.html
kmaraj/kmaraj
973bd4392607028afc52e502020bb8f26cc3e1a4
[ "MIT" ]
null
null
null
<html> <head> <link rel = "stylesheet" href="css/animate.css"> <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css" integrity="sha384-Vkoo8x4CGsO3+Hhxv8T/Q5PaXtkKtu6ug5TOeNV6gBiFeWPGFN9MuhOf23Q9Ifjh" crossorigin="anonymous"> <link href="css/main.css" rel="stylesheet" type="text/css"> <link href="https://fonts.googleapis.com/css2?family=Gotu&display=swap" rel="stylesheet"> <link href="https://fonts.googleapis.com/css2?family=Gotu&display=swap" rel="stylesheet"> <script src="https://static.opentok.com/v2/js/opentok.min.js"></script> </head> <body> <nav class="navbar navbar-expand-lg navbar-dark"> <a class="navbar-brand" href="index.html"><img src="img/hearticon_white.png" alt="Smiley face" height="50" width="50"></a> <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation"> <span class="navbar-toggler-icon"></span> </button> <div class="collapse navbar-collapse" id="navbarNav"> <ul class="navbar-nav"> <li class="nav-item active"> <a class="nav-link" href="why.html"> Love Actually <span class="sr-only">(current)</span></a> </li> <li class="nav-item active"> <a class="nav-link" href="works.html"> How Does This Work? <span class="sr-only">(current)</span></a> </li> <li class="nav-item active"> <a class="nav-link" href="testimonials.html"> Testimonials <span class="sr-only">(current)</span></a> </li> <li class="nav-item active"> <a class="nav-link" href="moderndating.html"> Modern Dating <span class="sr-only">(current)</span></a> </li> </ul> </div> </nav> <div class="container-fluid"> <div class="row content"> <div class="col-sm-6"> <!-- <div class="embed-responsive embed-responsive-1by1"> --> <iframe id="myframe" src="about:blank" style="display: block" width="100%" height="500px" scrolling="auto" allow="microphone; camera" ></iframe> </div> <div class="col-sm-6"> <div id="carouselExampleIndicators" class="carousel slide" data-ride="carousel" data-interval="false"> <ol class="carousel-indicators"> <li data-target="#carouselExampleIndicators" data-slide-to="0" class="active"></li> <li data-target="#carouselExampleIndicators" data-slide-to="1"></li> <li data-target="#carouselExampleIndicators" data-slide-to="2"></li> <li data-target="#carouselExampleIndicators" data-slide-to="3"></li> <li data-target="#carouselExampleIndicators" data-slide-to="4"></li> <li data-target="#carouselExampleIndicators" data-slide-to="5"></li> <li data-target="#carouselExampleIndicators" data-slide-to="6"></li> <li data-target="#carouselExampleIndicators" data-slide-to="7"></li> <li data-target="#carouselExampleIndicators" data-slide-to="8"></li> <li data-target="#carouselExampleIndicators" data-slide-to="9"></li> <li data-target="#carouselExampleIndicators" data-slide-to="10"></li> <li data-target="#carouselExampleIndicators" data-slide-to="11"></li> <li data-target="#carouselExampleIndicators" data-slide-to="12"></li> <li data-target="#carouselExampleIndicators" data-slide-to="13"></li> <li data-target="#carouselExampleIndicators" data-slide-to="14"></li> <li data-target="#carouselExampleIndicators" data-slide-to="15"></li> <li data-target="#carouselExampleIndicators" data-slide-to="16"></li> <li data-target="#carouselExampleIndicators" data-slide-to="17"></li> <li data-target="#carouselExampleIndicators" data-slide-to="18"></li> <li data-target="#carouselExampleIndicators" data-slide-to="19"></li> <li data-target="#carouselExampleIndicators" data-slide-to="20"></li> <li data-target="#carouselExampleIndicators" data-slide-to="21"></li> <li data-target="#carouselExampleIndicators" data-slide-to="22"></li> <li data-target="#carouselExampleIndicators" data-slide-to="23"></li> <li data-target="#carouselExampleIndicators" data-slide-to="24"></li> <li data-target="#carouselExampleIndicators" data-slide-to="25"></li> <li data-target="#carouselExampleIndicators" data-slide-to="26"></li> <li data-target="#carouselExampleIndicators" data-slide-to="27"></li> <li data-target="#carouselExampleIndicators" data-slide-to="28"></li> <li data-target="#carouselExampleIndicators" data-slide-to="29"></li> <li data-target="#carouselExampleIndicators" data-slide-to="30"></li> <li data-target="#carouselExampleIndicators" data-slide-to="31"></li> <li data-target="#carouselExampleIndicators" data-slide-to="32"></li> <li data-target="#carouselExampleIndicators" data-slide-to="33"></li> <li data-target="#carouselExampleIndicators" data-slide-to="34"></li> <li data-target="#carouselExampleIndicators" data-slide-to="35"></li> <li data-target="#carouselExampleIndicators" data-slide-to="36"></li> </ol> <div class="carousel-inner"> <div class="carousel-item active text-center"> <div class = "first_slide"> <h3 data-animation="animated bounceInDown"> Click the Right Slider to Start </h3> <img data-animation="animated bounceInLeft" src="icons/finger.png" height="50" width="50"> </div> </div> <!-- First question --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 1 </h4> <h3 data-animation="animated bounceInDown"> Given the choice of anyone in the world, whom would you want as a dinner guest? </h3> <img data-animation="animated bounceInUp" src="icons/1.png" height="100" width="100"> </div> </div> <!-- Second Question --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 2 </h4> <h3 data-animation="animated bounceInDown"> Would you like to be famous? In what way? </h3> <img data-animation="animated bounceInUp" src="icons/2.png" height="100" width="100"> </div> </div> <!-- Third Question --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 3 </h4> <h3 data-animation="animated bounceInDown"> Before making a telephone call, do you ever rehearse what you are going to say? Why? </h3> <img data-animation="animated bounceInUp" src="icons/3.png" height="100" width="100"> </div> </div> <!-- Fourth Question --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 4 </h4> <h3 data-animation="animated bounceInDown"> What would constitute a “perfect” day for you? </h3> <img data-animation="animated bounceInUp" src="icons/4.png" height="100" width="100"> </div> </div> <!-- Fifth Question --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 5 </h4> <h3 data-animation="animated bounceInDown"> When did you last sing to yourself? To someone else? </h3> <img data-animation="animated bounceInUp" src="icons/5.png" height="100" width="100"> </div> </div> <!-- Sixth Question --> <div class="carousel-item"> <div class = "other_slides3"> <h4 data-animation="animated bounceInDown"> 6 </h4> <h3 data-animation="animated bounceInDown"> If you were able to live to the age of 90 and retain either the mind or body of a 30-year-old for the last 60 years of your life, which would you want? </h3> <img data-animation="animated bounceInUp" src="icons/6.png" height="100" width="100"> </div> </div> <!-- Seventh Question --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 7 </h4> <h3 data-animation="animated bounceInDown"> Do you have a secret hunch about how you will die? </h3> <img data-animation="animated bounceInUp" src="icons/7.png" height="100" width="100"> </div> </div> <!-- Eighth Question --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 8 </h4> <h3 data-animation="animated bounceInDown"> Name three things you and your partner appear to have in common. </h3> <img data-animation="animated bounceInUp" src="icons/8.png" height="100" width="100"> </div> </div> <!-- Ninth Question --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 9 </h4> <h3 data-animation="animated bounceInDown"> For what in your life do you feel most grateful? </h3> <img data-animation="animated bounceInUp" src="icons/9.png" height="100" width="100"> </div> </div> <!-- Tenth Question --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 10 </h4> <h3 data-animation="animated bounceInDown"> If you could change anything about the way you were raised, what would it be? </h3> <img data-animation="animated bounceInUp" src="icons/10.png" height="100" width="100"> </div> </div> <!-- Eleventh Question --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 11 </h4> <h3 data-animation="animated bounceInDown"> Take four minutes and tell your partner your life story in as much detail as possible. </h3> <img data-animation="animated bounceInUp" src="icons/11.png" height="100" width="100"> </div> </div> <!-- 12 --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 12 </h4> <h3 data-animation="animated bounceInDown"> If you could wake up tomorrow having gained any one quality or ability, what would it be? </h3> <img data-animation="animated bounceInUp" src="icons/12.png" height="100" width="100"> </div> </div> <!--SET 2--> <!-- 13 --> <div class="carousel-item"> <div class = "other_slides2"> <h4 data-animation="animated bounceInDown"> 13 </h4> <h3 data-animation="animated bounceInDown"> If a crystal ball could tell you the truth about yourself, your life, the future or anything else, what would you want to know? </h3> <img data-animation="animated bounceInUp" src="icons/13.png" height="100" width="100"> </div> </div> <!-- 14 --> <div class="carousel-item"> <div class = "other_slides2"> <h4 data-animation="animated bounceInDown"> 14 </h4> <h3 data-animation="animated bounceInDown"> Is there something that you’ve dreamed of doing for a long time? Why haven’t you done it? </h3> <img data-animation="animated bounceInUp" src="icons/14.png" height="100" width="100"> </div> </div> <!-- 15 --> <div class="carousel-item"> <div class = "other_slides2"> <h4 data-animation="animated bounceInDown"> 15 </h4> <h3 data-animation="animated bounceInDown"> What is the greatest accomplishment of your life? </h3> <img data-animation="animated bounceInUp" src="icons/15.png" height="100" width="100"> </div> </div> <!-- 16 --> <div class="carousel-item"> <div class = "other_slides2"> <h4 data-animation="animated bounceInDown"> 16 </h4> <h3 data-animation="animated bounceInDown"> What do you value most in a friendship? </h3> <img data-animation="animated bounceInUp" src="icons/16.png" height="100" width="100"> </div> </div> <!-- 17 --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 17 </h4> <h3 data-animation="animated bounceInDown"> What is your most treasured memory? </h3> <img data-animation="animated bounceInUp" src="icons/17.png" height="100" width="100"> </div> </div> <!-- 18 --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 18 </h4> <h3 data-animation="animated bounceInDown"> What is your most terrible memory? </h3> <img data-animation="animated bounceInUp" src="icons/18.png" height="100" width="100"> </div> </div> <!-- 19 --> <div class="carousel-item"> <div class = "other_slides3"> <h4 data-animation="animated bounceInDown"> 19 </h4> <h3 data-animation="animated bounceInDown"> If you knew that in one year you would die suddenly, would you change anything about the way you are now living? Why? </h3> <img data-animation="animated bounceInUp" src="icons/19.png" height="100" width="100"> </div> </div> <!-- 20 --> <div class="carousel-item"> <div class = "other_slides2"> <h4 data-animation="animated bounceInDown"> 20 </h4> <h3 data-animation="animated bounceInDown"> What does friendship mean to you? </h3> <img data-animation="animated bounceInUp" src="icons/20.png" height="100" width="100"> </div> </div> <!-- 21 --> <div class="carousel-item"> <div class = "other_slides2"> <h4 data-animation="animated bounceInDown"> 21 </h4> <h3 data-animation="animated bounceInDown"> What roles do love and affection play in your life? </h3> <img data-animation="animated bounceInUp" src="icons/21.png" height="100" width="100"> </div> </div> <!-- 22 --> <div class="carousel-item"> <div class = "other_slides3"> <h4 data-animation="animated bounceInDown"> 22 </h4> <h3 data-animation="animated bounceInDown"> Alternate sharing something you consider a positive characteristic of your partner. Share a total of five items. </h3> <img data-animation="animated bounceInUp" src="icons/22.png" height="100" width="100"> </div> </div> <!-- 23 --> <div class="carousel-item"> <div class = "other_slides3"> <h4 data-animation="animated bounceInDown"> 23 </h4> <h3 data-animation="animated bounceInDown"> How close and warm is your family? Do you feel your childhood was happier than most other people’s? </h3> <img data-animation="animated bounceInUp" src="icons/23.png" height="100" width="100"> </div> </div> <!-- 24 --> <div class="carousel-item"> <div class = "other_slides2"> <h4 data-animation="animated bounceInDown"> 24 </h4> <h3 data-animation="animated bounceInDown"> How do you feel about your relationship with your mother? </h3> <img data-animation="animated bounceInUp" src="icons/24.png" height="100" width="100"> </div> </div> <!-- PART THREE --> <!-- 25 --> <div class="carousel-item"> <div class = "other_slides2"> <h4 data-animation="animated bounceInDown"> 25 </h4> <h3 data-animation="animated bounceInDown"> Make three true “we” statements each. For instance, “We are both in this room feeling ... ” </h3> <img data-animation="animated bounceInUp" src="icons/25.png" height="100" width="100"> </div> </div> <!-- 26 --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 26 </h4> <h3 data-animation="animated bounceInDown"> Complete this sentence: “I wish I had someone with whom I could share ... ” </h3> <img data-animation="animated bounceInUp" src="icons/26.png" height="100" width="100"> </div> </div> <!-- 27 --> <div class="carousel-item"> <div class = "other_slides2"> <h4 data-animation="animated bounceInDown"> 27 </h4> <h3 data-animation="animated bounceInDown"> If you were going to become a close friend with your partner, please share what would be important for him or her to know. </h3> <img data-animation="animated bounceInUp" src="icons/27.png" height="100" width="100"> </div> </div> <!-- 28 --> <div class="carousel-item"> <div class = "other_slides2"> <h4 data-animation="animated bounceInDown"> 28 </h4> <h3 data-animation="animated bounceInDown"> Tell your partner what you like about them; be very honest this time, saying things that you might not say to someone you’ve just met. </h3> <img data-animation="animated bounceInUp" src="icons/28.png" height="100" width="100"> </div> </div> <!-- 29 --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 29 </h4> <h3 data-animation="animated bounceInDown"> Share with your partner an embarrassing moment in your life. </h3> <img data-animation="animated bounceInUp" src="icons/29.png" height="100" width="100"> </div> </div> <!-- 30 --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 30 </h4> <h3 data-animation="animated bounceInDown"> When did you last cry in front of another person? By yourself? </h3> <img data-animation="animated bounceInUp" src="icons/30.png" height="100" width="100"> </div> </div> <!-- 31 --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 31 </h4> <h3 data-animation="animated bounceInDown"> Tell your partner something that you like about them already. </h3> <img data-animation="animated bounceInUp" src="icons/31.png" height="100" width="100"> </div> </div> <!-- 32 --> <div class="carousel-item"> <div class = "other_slides"> <h4 data-animation="animated bounceInDown"> 32 </h4> <h3 data-animation="animated bounceInDown"> What, if anything, is too serious to be joked about? </h3> <!-- <img data-animation="animated bounceInUp" src="icons/32.png" height="100" width="100"> --> </div> </div> <!-- 33 --> <div class="carousel-item"> <div class = "other_slides3"> <h4 data-animation="animated bounceInDown"> 33 </h4> <h3 data-animation="animated bounceInDown"> If you were to die this evening with no opportunity to communicate with anyone, what would you most regret not having told someone? Why haven’t you told them yet? </h3> <img data-animation="animated bounceInUp" src="icons/33.png" height="100" width="100"> </div> </div> <!-- 34 --> <div class="carousel-item"> <div class = "other_slides3"> <h4 data-animation="animated bounceInDown"> 34 </h4> <h3 data-animation="animated bounceInDown"> Your house, containing everything you own, catches fire. After saving your loved ones and pets, you have time to safely make a final dash to save any one item. What would it be? Why? </h3> <img data-animation="animated bounceInUp" src="icons/34.png" height="100" width="100"> </div> </div> <!-- 35 --> <div class="carousel-item"> <div class = "other_slides2"> <h4 data-animation="animated bounceInDown"> 35 </h4> <h3 data-animation="animated bounceInDown"> Of all the people in your family, whose death would you find most disturbing? Why? </h3> <img data-animation="animated bounceInUp" src="icons/35.png" height="100" width="100"> </div> </div> <!-- 36 --> <div class="carousel-item"> <div class = "other_slides3"> <h4 data-animation="animated bounceInDown"> 36 </h4> <h3 data-animation="animated bounceInDown"> Share a personal problem and ask your partner’s advice on how he or she might handle it. Also, ask your partner to reflect back to you how you seem to be feeling about the problem you have chosen. </h3> <img data-animation="animated bounceInUp" src="icons/36.png" height="100" width="100"> </div> </div> </div> <a class="carousel-control-prev" href="#carouselExampleIndicators" role="button" data-slide="prev"> <span class="carousel-control-prev-icon" aria-hidden="true"></span> <span class="sr-only">Previous</span> </a> <a class="carousel-control-next" href="#carouselExampleIndicators" role="button" data-slide="next"> <span class="carousel-control-next-icon" aria-hidden="true"></span> <span class="sr-only">Next</span> </a> </div> <!-- <div id="carouselExampleIndicators" class="carousel slide" data-interval="false"> <ol class="carousel-indicators"> <li data-target="#carouselExampleIndicators" data-slide-to="0" class="active"></li> <li data-target="#carouselExampleIndicators" data-slide-to="1"></li> <li data-target="#carouselExampleIndicators" data-slide-to="2"></li> <li data-target="#carouselExampleIndicators" data-slide-to="3"></li> </ol> <div class="carousel-inner "> <div class="carousel-item active"> <div class="carousel-caption d-md-block"> <h3 data-animation="animated bounceInDown"> Click the Right Slider to Start </h3> <img data-animation="animated bounceInLeft" src="icons/finger.png" height="50" width="50"> </div> </div> <div class="carousel-item "> <div class="carousel-caption d-md-block"> <h2> 1 </h2> <h3 data-animation="animated bounceInUp"> Given the choice of anyone in the world, whom would you want as a dinner guest? </h3> <img data-animation="animated bounceInLeft" src="icons/1.png" height="50" width="50"> </div> </div> <div class="carousel-item "> <div class="carousel-caption d-md-block"> <h3 class="icon-container" data-animation="animated zoomInLeft"> <span class="fa fa-glass"></span> </h3> <h3 data-animation="animated flipInX"> This is the caption for slide 3 </h3> <button class="btn btn-primary btn-lg" data-animation="animated lightSpeedIn">Button</button> </div> </div> <div class="carousel-item "> <div class="carousel-caption d-md-block"> <h3 class="icon-container" data-animation="animated zoomInLeft"> <span class="fa fa-glass"></span> </h3> <h3 data-animation="animated flipInX"> This is the caption for slide 3 </h3> <button class="btn btn-primary btn-lg" data-animation="animated lightSpeedIn">Button</button> </div> </div> </div> <a class="carousel-control-prev" href="#carouselExampleIndicators" role="button" data-slide="prev"> <span class="carousel-control-prev-icon" aria-hidden="true"></span> <span class="sr-only">Previous</span> </a> <a class="carousel-control-next" href="#carouselExampleIndicators" role="button" data-slide="next"> <span class="carousel-control-next-icon" aria-hidden="true"></span> <span class="sr-only">Next</span> </a> </div> --> </div> </div> </div> <script src="https://code.jquery.com/jquery-3.4.1.slim.min.js" integrity="sha384-J6qa4849blE2+poT4WnyKhv5vZF5SrPo0iEjwBvKU7imGFAV0wwj1yYfoRSJoZ+n" crossorigin="anonymous"></script> <script src="https://cdn.jsdelivr.net/npm/popper.js@1.16.0/dist/umd/popper.min.js" integrity="sha384-Q6E9RHvbIyZFJoft+2mJbHaEWldlvI9IOYy5n3zV9zzTtmI3UksdQRVvoxMfooAo" crossorigin="anonymous"></script> <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/js/bootstrap.min.js" integrity="sha384-wfSDF2E50Y2D1uUdj0O3uMBJnjuUD4Ih7YwaYd1iqfktj0Uod8GCExl3Og8ifwB6" crossorigin="anonymous"></script> <script type="text/javascript" src="js/app.js"></script> </body> </html>
31.546061
212
0.649865
5e41736a70e96e0fb2d380711fb9421cd615da2b
44,912
sql
SQL
shop.sql
lhy757208/shop
83c44350e8aa5cca30c998465067216227b99020
[ "Apache-2.0" ]
null
null
null
shop.sql
lhy757208/shop
83c44350e8aa5cca30c998465067216227b99020
[ "Apache-2.0" ]
null
null
null
shop.sql
lhy757208/shop
83c44350e8aa5cca30c998465067216227b99020
[ "Apache-2.0" ]
null
null
null
/* Navicat Premium Data Transfer Source Server : localhost Source Server Type : MySQL Source Server Version : 50723 Source Host : localhost:3306 Source Schema : shop Target Server Type : MySQL Target Server Version : 50723 File Encoding : 65001 Date: 18/09/2020 17:26:12 */ SET NAMES utf8mb4; SET FOREIGN_KEY_CHECKS = 0; -- ---------------------------- -- Table structure for banner -- ---------------------------- DROP TABLE IF EXISTS `banner`; CREATE TABLE `banner` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT 'Banner名称,通常作为标识', `description` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT 'Banner描述', `create_time` int(11) DEFAULT NULL, `update_time` int(11) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 212 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = 'banner管理表' ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of banner -- ---------------------------- INSERT INTO `banner` VALUES (1, '首页置顶9999', '首页轮播图', NULL, 1599721268); INSERT INTO `banner` VALUES (3, '首页置顶2', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (4, '首页置顶3', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (5, '首页置顶4', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (6, '首页置顶5', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (7, '首页置顶6', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (8, '首页置顶7', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (9, '首页置顶8', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (10, '首页置顶9', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (11, '首页置顶12', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (12, '首页置顶23', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (13, '首页置顶34', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (14, '首页置顶45', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (15, '首页置顶56', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (16, '首页置顶17', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (17, '首页置顶18', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (18, '首页置顶19', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (19, '首页置顶72', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (20, '首页置顶73', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (21, '首页置顶74', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (22, '首页置顶75', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (23, '首页置顶76', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (24, '首页置顶77', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (25, '首页置顶78', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (26, '首页置顶79', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (27, '首页置顶28', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (28, '首页置顶83', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (29, '首页置顶84', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (30, '首页置顶85', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (31, '首页置顶86', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (32, '首页置顶87', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (33, '首页置顶88', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (34, '首页置顶89', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (35, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (36, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (37, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (38, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (39, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (40, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (41, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (42, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (43, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (44, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (45, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (46, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (47, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (48, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (49, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (50, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (51, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (52, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (53, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (54, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (55, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (56, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (57, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (58, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (59, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (60, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (61, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (62, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (63, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (64, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (65, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (66, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (67, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (68, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (69, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (70, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (71, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (72, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (73, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (74, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (75, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (76, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (77, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (78, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (79, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (80, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (81, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (82, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (83, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (84, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (85, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (86, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (87, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (88, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (89, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (90, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (91, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (92, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (93, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (94, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (95, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (96, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (97, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (98, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (99, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (100, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (101, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (102, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (103, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (104, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (105, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (106, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (107, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (108, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (109, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (110, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (111, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (112, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (113, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (114, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (115, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (116, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (117, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (118, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (119, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (120, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (121, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (122, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (123, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (124, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (125, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (126, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (127, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (128, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (129, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (130, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (131, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (132, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (133, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (134, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (135, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (136, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (137, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (138, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (139, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (140, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (141, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (142, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (143, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (144, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (145, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (146, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (147, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (148, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (149, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (150, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (151, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (152, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (153, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (154, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (155, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (156, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (157, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (158, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (159, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (160, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (161, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (162, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (163, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (164, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (165, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (166, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (167, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (168, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (169, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (170, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (171, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (172, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (173, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (174, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (175, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (176, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (177, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (178, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (179, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (180, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (181, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (182, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (183, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (184, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (185, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (186, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (187, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (188, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (189, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (190, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (191, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (192, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (193, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (194, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (195, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (196, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (197, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (198, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (199, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (200, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (201, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (202, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (203, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (204, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (205, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (206, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (207, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (208, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (209, '首页置顶', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (210, 'xiaoy111', '首页轮播图', NULL, NULL); INSERT INTO `banner` VALUES (211, 'admin', '首页轮播图', NULL, NULL); -- ---------------------------- -- Table structure for banner_item -- ---------------------------- DROP TABLE IF EXISTS `banner_item`; CREATE TABLE `banner_item` ( `id` int(11) NOT NULL AUTO_INCREMENT, `img_id` int(11) NOT NULL COMMENT '外键,关联image表', `key_word` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '执行关键字,根据不同的type含义不同', `type` tinyint(4) NOT NULL DEFAULT 1 COMMENT '跳转类型,可能导向商品,可能导向专题,可能导向其他。0,无导向;1:导向商品;2:导向专题', `delete_time` int(11) DEFAULT NULL, `banner_id` int(11) NOT NULL COMMENT '外键,关联banner表', `update_time` int(11) DEFAULT NULL, `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '标题', `description` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '描述', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 6 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = 'banner子项表' ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of banner_item -- ---------------------------- INSERT INTO `banner_item` VALUES (1, 65, '6', 1, NULL, 1, NULL, NULL, NULL); INSERT INTO `banner_item` VALUES (2, 2, '25', 1, NULL, 1, NULL, NULL, NULL); INSERT INTO `banner_item` VALUES (3, 3, '11', 1, NULL, 1, NULL, NULL, NULL); INSERT INTO `banner_item` VALUES (5, 1, '10', 1, NULL, 1, NULL, NULL, NULL); -- ---------------------------- -- Table structure for category -- ---------------------------- DROP TABLE IF EXISTS `category`; CREATE TABLE `category` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '分类名称', `topic_img_id` int(11) DEFAULT NULL COMMENT '外键,关联image表', `delete_time` int(11) DEFAULT NULL, `description` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '描述', `update_time` int(11) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 8 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '商品类目' ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of category -- ---------------------------- INSERT INTO `category` VALUES (2, '果味', 6, NULL, NULL, NULL); INSERT INTO `category` VALUES (3, '蔬菜', 5, NULL, NULL, NULL); INSERT INTO `category` VALUES (4, '炒货', 7, NULL, NULL, NULL); INSERT INTO `category` VALUES (5, '点心', 4, NULL, NULL, NULL); INSERT INTO `category` VALUES (6, '粗茶', 8, NULL, NULL, NULL); INSERT INTO `category` VALUES (7, '淡饭', 9, NULL, NULL, NULL); -- ---------------------------- -- Table structure for image -- ---------------------------- DROP TABLE IF EXISTS `image`; CREATE TABLE `image` ( `id` int(11) NOT NULL AUTO_INCREMENT, `url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '图片路径', `from` tinyint(4) NOT NULL DEFAULT 1 COMMENT '1 来自本地,2 来自公网', `delete_time` int(11) DEFAULT NULL, `update_time` int(11) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 106 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '图片总表' ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of image -- ---------------------------- INSERT INTO `image` VALUES (1, '/banner-1a.png', 1, NULL, NULL); INSERT INTO `image` VALUES (2, '/banner-2a.png', 1, NULL, NULL); INSERT INTO `image` VALUES (3, '/banner-3a.png', 1, NULL, NULL); INSERT INTO `image` VALUES (4, '/category-cake.png', 1, NULL, NULL); INSERT INTO `image` VALUES (5, '/category-vg.png', 1, NULL, NULL); INSERT INTO `image` VALUES (6, '/category-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (7, '/category-fry-a.png', 1, NULL, NULL); INSERT INTO `image` VALUES (8, '/category-tea.png', 1, NULL, NULL); INSERT INTO `image` VALUES (9, '/category-rice.png', 1, NULL, NULL); INSERT INTO `image` VALUES (10, '/product-dryfruit@1.png', 1, NULL, NULL); INSERT INTO `image` VALUES (13, '/product-vg@1.png', 1, NULL, NULL); INSERT INTO `image` VALUES (14, '/product-rice@6.png', 1, NULL, NULL); INSERT INTO `image` VALUES (16, '/1@theme.png', 1, NULL, NULL); INSERT INTO `image` VALUES (17, '/2@theme.png', 1, NULL, NULL); INSERT INTO `image` VALUES (18, '/3@theme.png', 1, NULL, NULL); INSERT INTO `image` VALUES (19, '/detail-1@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (20, '/detail-2@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (21, '/detail-3@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (22, '/detail-4@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (23, '/detail-5@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (24, '/detail-6@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (25, '/detail-7@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (26, '/detail-8@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (27, '/detail-9@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (28, '/detail-11@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (29, '/detail-10@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (31, '/product-rice@1.png', 1, NULL, NULL); INSERT INTO `image` VALUES (32, '/product-tea@1.png', 1, NULL, NULL); INSERT INTO `image` VALUES (33, '/product-dryfruit@2.png', 1, NULL, NULL); INSERT INTO `image` VALUES (36, '/product-dryfruit@3.png', 1, NULL, NULL); INSERT INTO `image` VALUES (37, '/product-dryfruit@4.png', 1, NULL, NULL); INSERT INTO `image` VALUES (38, '/product-dryfruit@5.png', 1, NULL, NULL); INSERT INTO `image` VALUES (39, '/product-dryfruit-a@6.png', 1, NULL, NULL); INSERT INTO `image` VALUES (40, '/product-dryfruit@7.png', 1, NULL, NULL); INSERT INTO `image` VALUES (41, '/product-rice@2.png', 1, NULL, NULL); INSERT INTO `image` VALUES (42, '/product-rice@3.png', 1, NULL, NULL); INSERT INTO `image` VALUES (43, '/product-rice@4.png', 1, NULL, NULL); INSERT INTO `image` VALUES (44, '/product-fry@1.png', 1, NULL, NULL); INSERT INTO `image` VALUES (45, '/product-fry@2.png', 1, NULL, NULL); INSERT INTO `image` VALUES (46, '/product-fry@3.png', 1, NULL, NULL); INSERT INTO `image` VALUES (47, '/product-tea@2.png', 1, NULL, NULL); INSERT INTO `image` VALUES (48, '/product-tea@3.png', 1, NULL, NULL); INSERT INTO `image` VALUES (49, '/1@theme-head.png', 1, NULL, NULL); INSERT INTO `image` VALUES (50, '/2@theme-head.png', 1, NULL, NULL); INSERT INTO `image` VALUES (51, '/3@theme-head.png', 1, NULL, NULL); INSERT INTO `image` VALUES (52, '/product-cake@1.png', 1, NULL, NULL); INSERT INTO `image` VALUES (53, '/product-cake@2.png', 1, NULL, NULL); INSERT INTO `image` VALUES (54, '/product-cake-a@3.png', 1, NULL, NULL); INSERT INTO `image` VALUES (55, '/product-cake-a@4.png', 1, NULL, NULL); INSERT INTO `image` VALUES (56, '/product-dryfruit@8.png', 1, NULL, NULL); INSERT INTO `image` VALUES (57, '/product-fry@4.png', 1, NULL, NULL); INSERT INTO `image` VALUES (58, '/product-fry@5.png', 1, NULL, NULL); INSERT INTO `image` VALUES (59, '/product-rice@5.png', 1, NULL, NULL); INSERT INTO `image` VALUES (60, '/product-rice@7.png', 1, NULL, NULL); INSERT INTO `image` VALUES (62, '/detail-12@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (63, '/detail-13@1-dryfruit.png', 1, NULL, NULL); INSERT INTO `image` VALUES (65, '/banner-4a.png', 1, NULL, NULL); INSERT INTO `image` VALUES (66, '/product-vg@4.png', 1, NULL, NULL); INSERT INTO `image` VALUES (67, '/product-vg@5.png', 1, NULL, NULL); INSERT INTO `image` VALUES (68, '/product-vg@2.png', 1, NULL, NULL); INSERT INTO `image` VALUES (69, '/product-vg@3.png', 1, NULL, NULL); INSERT INTO `image` VALUES (70, '20200911\\0d3a7b665e6e21dd1eff068b518ef3a0.jpg', 1, NULL, 1599787850); INSERT INTO `image` VALUES (71, '20200911\\b2dddf0c03e2ef1fa90be269083e4ac8.jpg', 1, NULL, 1599787982); INSERT INTO `image` VALUES (72, '20200911\\aa28f35b0f7b375f12d788a9f7e8bfde.jpg', 1, NULL, 1599788318); INSERT INTO `image` VALUES (73, '20200911\\cbe54cce7e7cf27ec395e3652ad99a22.jpg', 1, NULL, 1599788322); INSERT INTO `image` VALUES (74, '20200911\\5e45cf13860f654a222cbd8a6b96e500.jpg', 1, NULL, 1599788324); INSERT INTO `image` VALUES (75, '20200911\\ee32f14822d8d82d9f10706b056d9f5e.jpg', 1, NULL, 1599788326); INSERT INTO `image` VALUES (76, '20200911\\033dfbd6e804c57507e584fd9f9c9443.jpg', 1, NULL, 1599788369); INSERT INTO `image` VALUES (77, '20200911\\44545ac7a50ced77ab4593965c9de54a.jpg', 1, NULL, 1599788407); INSERT INTO `image` VALUES (78, '20200911\\cf0236af5b3a0476a2d2463daf5f11e2.jpg', 1, NULL, 1599788410); INSERT INTO `image` VALUES (79, '20200911\\c298be176e33ff86566d488706c2f588.jpg', 1, NULL, 1599788495); INSERT INTO `image` VALUES (80, '20200911\\f6a6ee1b457b825e9d0b17b9f2dd80a4.jpg', 1, NULL, 1599788503); INSERT INTO `image` VALUES (81, '20200911\\cba78de0c890689f63dadbb789bcfcb4.jpg', 1, NULL, 1599788514); INSERT INTO `image` VALUES (82, '20200911\\975f24884a4c5e85b64418f07784b8bd.jpg', 1, NULL, 1599788522); INSERT INTO `image` VALUES (83, '20200911\\c30438ac83e7b818bc65fbc9204e5d44.jpg', 1, NULL, 1599788523); INSERT INTO `image` VALUES (84, '20200911\\bc69b71bd5a03f5f92190a1e3b1f80a5.jpg', 1, NULL, 1599788526); INSERT INTO `image` VALUES (85, '20200911\\f4723269d7002595b0c965765a2837b4.jpg', 1, NULL, 1599788527); INSERT INTO `image` VALUES (86, '20200911\\134f742de52c1c3061c7520c01679ac1.jpg', 1, NULL, 1599788546); INSERT INTO `image` VALUES (87, '20200911\\a7e1e5e99b658dca14f926a0e1dba246.jpg', 1, NULL, 1599788557); INSERT INTO `image` VALUES (88, '20200911\\5f3b4ad4453f07b02b46bf81d899ae6b.jpg', 1, NULL, 1599788586); INSERT INTO `image` VALUES (89, '20200911\\67c8af6b548fc6a5eff5cd3bf03678ee.jpg', 1, NULL, 1599788687); INSERT INTO `image` VALUES (90, '20200911\\96e680908ccc74281e8fee4f999e81f7.jpg', 1, NULL, 1599788689); INSERT INTO `image` VALUES (91, '20200911\\f47b80fc5f8f5146ce77f11c8d458e8c.jpg', 1, NULL, 1599788704); INSERT INTO `image` VALUES (92, '20200911\\3ea547f73c5b637e3f492e3bcab7fc94.jpg', 1, NULL, 1599788717); INSERT INTO `image` VALUES (93, '20200911\\b0c6fc93366c0b6dde2caf656e43aa9c.jpg', 1, NULL, 1599788720); INSERT INTO `image` VALUES (94, '20200911\\7982bc7f551077f692ebfea75a9232e9.jpg', 1, NULL, 1599788773); INSERT INTO `image` VALUES (95, '20200911\\552b17877197a4bdb2db91614ec618fe.jpg', 1, NULL, 1599788776); INSERT INTO `image` VALUES (96, '20200911\\cad3abf294e880870c5de3360af08e8a.jpg', 1, NULL, 1599788779); INSERT INTO `image` VALUES (97, '20200911\\2d446aead3bb0a4fd7a706e4f60e2933.jpg', 1, NULL, 1599788798); INSERT INTO `image` VALUES (98, '20200911\\ce729f32ea29e33b60c5848493eb854d.jpg', 1, NULL, 1599788824); INSERT INTO `image` VALUES (99, '20200911\\1b6e4c3f56e0868b24c9828b53276155.jpg', 1, NULL, 1599788915); INSERT INTO `image` VALUES (100, '20200911\\060e6843ec1d84616fbb1a1707f9dcd8.jpg', 1, NULL, 1599788942); INSERT INTO `image` VALUES (101, '20200911\\318f3c0e38908ed7a796b0c2fdd67789.jpg', 1, NULL, 1599788948); INSERT INTO `image` VALUES (102, '20200911\\eac4cd0adf49f35a1feb04122dbe6092.jpg', 1, NULL, 1599789018); INSERT INTO `image` VALUES (103, '20200911\\62766d5e5b0b94b68d5e477f9b961aaf.jpg', 1, NULL, 1599789025); INSERT INTO `image` VALUES (104, '20200911\\a2cdf28ca4e183f8d32e34f9d9539368.jpg', 1, NULL, 1599789048); INSERT INTO `image` VALUES (105, '20200911\\a2a98ae06b8fcf411d0e6c6429f711d2.jpg', 1, NULL, 1599789096); -- ---------------------------- -- Table structure for order -- ---------------------------- DROP TABLE IF EXISTS `order`; CREATE TABLE `order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `order_no` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '订单号', `user_id` int(11) NOT NULL COMMENT '外键,用户id,注意并不是openid', `delete_time` int(11) DEFAULT NULL, `create_time` int(11) DEFAULT NULL, `total_price` decimal(6, 2) NOT NULL, `status` tinyint(4) NOT NULL DEFAULT 1 COMMENT '1:未支付, 2:已支付,3:已发货 , 4: 已支付,但库存不足', `snap_img` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '订单快照图片', `snap_name` varchar(80) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '订单快照名称', `total_count` int(11) NOT NULL DEFAULT 0, `update_time` int(11) DEFAULT NULL, `snap_items` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci COMMENT '订单其他信息快照(json)', `snap_address` varchar(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '地址快照', `prepay_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '订单微信支付的预订单id(用于发送模板消息)', PRIMARY KEY (`id`) USING BTREE, UNIQUE INDEX `order_no`(`order_no`) USING BTREE, INDEX `user_id`(`user_id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for order_product -- ---------------------------- DROP TABLE IF EXISTS `order_product`; CREATE TABLE `order_product` ( `order_id` int(11) NOT NULL COMMENT '联合主键,订单id', `product_id` int(11) NOT NULL COMMENT '联合主键,商品id', `count` int(11) NOT NULL COMMENT '商品数量', `delete_time` int(11) DEFAULT NULL, `update_time` int(11) DEFAULT NULL, PRIMARY KEY (`product_id`, `order_id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Table structure for product -- ---------------------------- DROP TABLE IF EXISTS `product`; CREATE TABLE `product` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(80) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '商品名称', `price` decimal(6, 2) NOT NULL COMMENT '价格,单位:分', `stock` int(11) NOT NULL DEFAULT 0 COMMENT '库存量', `delete_time` int(11) DEFAULT NULL, `category_id` int(11) DEFAULT NULL, `main_img_url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '主图ID号,这是一个反范式设计,有一定的冗余', `from` tinyint(4) NOT NULL DEFAULT 1 COMMENT '图片来自 1 本地 ,2公网', `create_time` int(11) DEFAULT NULL COMMENT '创建时间', `update_time` int(11) DEFAULT NULL, `summary` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '摘要', `img_id` int(11) DEFAULT NULL COMMENT '图片外键', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 34 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of product -- ---------------------------- INSERT INTO `product` VALUES (1, '芹菜 半斤', 0.01, 998, NULL, 3, '/product-vg@1.png', 1, NULL, NULL, NULL, 13); INSERT INTO `product` VALUES (2, '梨花带雨 3个', 0.01, 984, NULL, 2, '/product-dryfruit@1.png', 1, NULL, NULL, NULL, 10); INSERT INTO `product` VALUES (3, '素米 327克', 0.01, 996, NULL, 7, '/product-rice@1.png', 1, NULL, NULL, NULL, 31); INSERT INTO `product` VALUES (4, '红袖枸杞 6克*3袋', 0.01, 998, NULL, 6, '/product-tea@1.png', 1, NULL, NULL, NULL, 32); INSERT INTO `product` VALUES (5, '春生龙眼 500克', 0.01, 995, NULL, 2, '/product-dryfruit@2.png', 1, NULL, NULL, NULL, 33); INSERT INTO `product` VALUES (6, '小红的猪耳朵 120克', 0.01, 997, NULL, 5, '/product-cake@2.png', 1, NULL, NULL, NULL, 53); INSERT INTO `product` VALUES (7, '泥蒿 半斤', 0.01, 998, NULL, 3, '/product-vg@2.png', 1, NULL, NULL, NULL, 68); INSERT INTO `product` VALUES (8, '夏日芒果 3个', 0.01, 995, NULL, 2, '/product-dryfruit@3.png', 1, NULL, NULL, NULL, 36); INSERT INTO `product` VALUES (9, '冬木红枣 500克', 0.01, 996, NULL, 2, '/product-dryfruit@4.png', 1, NULL, NULL, NULL, 37); INSERT INTO `product` VALUES (10, '万紫千凤梨 300克', 0.01, 996, NULL, 2, '/product-dryfruit@5.png', 1, NULL, NULL, NULL, 38); INSERT INTO `product` VALUES (11, '贵妃笑 100克', 0.01, 994, NULL, 2, '/product-dryfruit-a@6.png', 1, NULL, NULL, NULL, 39); INSERT INTO `product` VALUES (12, '珍奇异果 3个', 0.01, 999, NULL, 2, '/product-dryfruit@7.png', 1, NULL, NULL, NULL, 40); INSERT INTO `product` VALUES (13, '绿豆 125克', 0.01, 999, NULL, 7, '/product-rice@2.png', 1, NULL, NULL, NULL, 41); INSERT INTO `product` VALUES (14, '芝麻 50克', 0.01, 999, NULL, 7, '/product-rice@3.png', 1, NULL, NULL, NULL, 42); INSERT INTO `product` VALUES (15, '猴头菇 370克', 0.01, 999, NULL, 7, '/product-rice@4.png', 1, NULL, NULL, NULL, 43); INSERT INTO `product` VALUES (16, '西红柿 1斤', 0.01, 999, NULL, 3, '/product-vg@3.png', 1, NULL, NULL, NULL, 69); INSERT INTO `product` VALUES (17, '油炸花生 300克', 0.01, 999, NULL, 4, '/product-fry@1.png', 1, NULL, NULL, NULL, 44); INSERT INTO `product` VALUES (18, '春泥西瓜子 128克', 0.01, 997, NULL, 4, '/product-fry@2.png', 1, NULL, NULL, NULL, 45); INSERT INTO `product` VALUES (19, '碧水葵花籽 128克', 0.01, 999, NULL, 4, '/product-fry@3.png', 1, NULL, NULL, NULL, 46); INSERT INTO `product` VALUES (20, '碧螺春 12克*3袋', 0.01, 999, NULL, 6, '/product-tea@2.png', 1, NULL, NULL, NULL, 47); INSERT INTO `product` VALUES (21, '西湖龙井 8克*3袋', 0.01, 998, NULL, 6, '/product-tea@3.png', 1, NULL, NULL, NULL, 48); INSERT INTO `product` VALUES (22, '梅兰清花糕 1个', 0.01, 997, NULL, 5, '/product-cake-a@3.png', 1, NULL, NULL, NULL, 54); INSERT INTO `product` VALUES (23, '清凉薄荷糕 1个', 0.01, 998, NULL, 5, '/product-cake-a@4.png', 1, NULL, NULL, NULL, 55); INSERT INTO `product` VALUES (25, '小明的妙脆角 120克', 0.01, 999, NULL, 5, '/product-cake@1.png', 1, NULL, NULL, NULL, 52); INSERT INTO `product` VALUES (26, '红衣青瓜 混搭160克', 0.01, 999, NULL, 2, '/product-dryfruit@8.png', 1, NULL, NULL, NULL, 56); INSERT INTO `product` VALUES (27, '锈色瓜子 100克', 0.01, 998, NULL, 4, '/product-fry@4.png', 1, NULL, NULL, NULL, 57); INSERT INTO `product` VALUES (28, '春泥花生 200克', 0.01, 999, NULL, 4, '/product-fry@5.png', 1, NULL, NULL, NULL, 58); INSERT INTO `product` VALUES (29, '冰心鸡蛋 2个', 0.01, 999, NULL, 7, '/product-rice@5.png', 1, NULL, NULL, NULL, 59); INSERT INTO `product` VALUES (30, '八宝莲子 200克', 0.01, 999, NULL, 7, '/product-rice@6.png', 1, NULL, NULL, NULL, 14); INSERT INTO `product` VALUES (31, '深涧木耳 78克', 0.01, 999, NULL, 7, '/product-rice@7.png', 1, NULL, NULL, NULL, 60); INSERT INTO `product` VALUES (32, '土豆 半斤', 0.01, 999, NULL, 3, '/product-vg@4.png', 1, NULL, NULL, NULL, 66); INSERT INTO `product` VALUES (33, '青椒 半斤', 0.01, 999, NULL, 3, '/product-vg@5.png', 1, NULL, NULL, NULL, 67); -- ---------------------------- -- Table structure for product_image -- ---------------------------- DROP TABLE IF EXISTS `product_image`; CREATE TABLE `product_image` ( `id` int(11) NOT NULL AUTO_INCREMENT, `img_id` int(11) NOT NULL COMMENT '外键,关联图片表', `delete_time` int(11) DEFAULT NULL COMMENT '状态,主要表示是否删除,也可以扩展其他状态', `order` int(11) NOT NULL DEFAULT 0 COMMENT '图片排序序号', `product_id` int(11) NOT NULL COMMENT '商品id,外键', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 20 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of product_image -- ---------------------------- INSERT INTO `product_image` VALUES (4, 19, NULL, 1, 11); INSERT INTO `product_image` VALUES (5, 20, NULL, 2, 11); INSERT INTO `product_image` VALUES (6, 21, NULL, 3, 11); INSERT INTO `product_image` VALUES (7, 22, NULL, 4, 11); INSERT INTO `product_image` VALUES (8, 23, NULL, 5, 11); INSERT INTO `product_image` VALUES (9, 24, NULL, 6, 11); INSERT INTO `product_image` VALUES (10, 25, NULL, 7, 11); INSERT INTO `product_image` VALUES (11, 26, NULL, 8, 11); INSERT INTO `product_image` VALUES (12, 27, NULL, 9, 11); INSERT INTO `product_image` VALUES (13, 28, NULL, 11, 11); INSERT INTO `product_image` VALUES (14, 29, NULL, 10, 11); INSERT INTO `product_image` VALUES (18, 62, NULL, 12, 11); INSERT INTO `product_image` VALUES (19, 63, NULL, 13, 11); -- ---------------------------- -- Table structure for product_property -- ---------------------------- DROP TABLE IF EXISTS `product_property`; CREATE TABLE `product_property` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(30) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '详情属性名称', `detail` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '详情属性', `product_id` int(11) NOT NULL COMMENT '商品id,外键', `delete_time` int(11) DEFAULT NULL, `update_time` int(11) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 9 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of product_property -- ---------------------------- INSERT INTO `product_property` VALUES (1, '品名', '杨梅', 11, NULL, NULL); INSERT INTO `product_property` VALUES (2, '口味', '青梅味 雪梨味 黄桃味 菠萝味', 11, NULL, NULL); INSERT INTO `product_property` VALUES (3, '产地', '火星', 11, NULL, NULL); INSERT INTO `product_property` VALUES (4, '保质期', '180天', 11, NULL, NULL); INSERT INTO `product_property` VALUES (5, '品名', '梨子', 2, NULL, NULL); INSERT INTO `product_property` VALUES (6, '产地', '金星', 2, NULL, NULL); INSERT INTO `product_property` VALUES (7, '净含量', '100g', 2, NULL, NULL); INSERT INTO `product_property` VALUES (8, '保质期', '10天', 2, NULL, NULL); -- ---------------------------- -- Table structure for shop_admin_user -- ---------------------------- DROP TABLE IF EXISTS `shop_admin_user`; CREATE TABLE `shop_admin_user` ( `uid` smallint(5) NOT NULL AUTO_INCREMENT, `username` varchar(16) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '', `password` char(32) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '', `tjdm` varchar(200) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '' COMMENT '统计代码', `lastip` varchar(15) CHARACTER SET utf8 COLLATE utf8_general_ci DEFAULT NULL COMMENT '上次登录IP', `nowip` varchar(15) CHARACTER SET utf8 COLLATE utf8_general_ci DEFAULT NULL COMMENT '本次ip', `lasttime` int(10) NOT NULL COMMENT '上次登录时间', `nowtime` int(10) NOT NULL COMMENT '本次登录时间', `status` tinyint(1) NOT NULL DEFAULT 1 COMMENT '状态1正常', `logincount` int(10) NOT NULL COMMENT '登录次数', `group_id` smallint(5) NOT NULL COMMENT '管理员组id', `salt` tinyint(255) DEFAULT NULL COMMENT '密码加盐 md5(输入的+)', PRIMARY KEY (`uid`) USING BTREE, INDEX `status`(`status`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 19 CHARACTER SET = utf8 COLLATE = utf8_general_ci COMMENT = '管理员表' ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of shop_admin_user -- ---------------------------- INSERT INTO `shop_admin_user` VALUES (1, 'admin', '17f4661ddeade2489e0fe1a3db7055bc', '', '127.0.0.1', '127.0.0.1', 1599557167, 1599617025, 1, 2538, 1, 1); INSERT INTO `shop_admin_user` VALUES (2, 'guyx', '95bfc9859972c207c5863521fc725dba', '', '222.93.54.196', '218.79.36.153', 1584969522, 1585012465, 1, 68, 2, 1); INSERT INTO `shop_admin_user` VALUES (4, 'huangzq', '95bfc9859972c207c5863521fc725dba', '', '114.86.140.38', '218.79.36.153', 1585003630, 1585009234, 1, 180, 2, 3); INSERT INTO `shop_admin_user` VALUES (6, 'gengsh', 'b3079fc96658221f07c6a1a98a9f5ceb', '', '218.79.36.153', '218.79.36.153', 1585020855, 1585020867, 1, 32, 1, 2); INSERT INTO `shop_admin_user` VALUES (8, 'liuhaiyang', '6978915ee7dbc5aff1bc34b59e8c0fc5', '', '127.0.0.1', '127.0.0.1', 1600046780, 1600077831, 1, 56, 1, 2); INSERT INTO `shop_admin_user` VALUES (9, 'testgame', '4fb2fc89d6607bd1ef429dc238f7a2d2', '', '114.86.140.38', '218.79.36.153', 1584969521, 1585029336, 1, 21, 8, 3); INSERT INTO `shop_admin_user` VALUES (10, '程钊', '1e10c1542a7eee55f6799a61b59875ff', '', '114.88.107.190', '114.88.107.190', 1584928466, 1585012207, 1, 59, 7, 2); INSERT INTO `shop_admin_user` VALUES (11, '潘旻辉', '02c8210be1a9e83fe698b67de2cbbe0e', '', '218.81.23.100', '218.81.188.185', 1584928624, 1585013001, 1, 54, 4, 2); INSERT INTO `shop_admin_user` VALUES (12, '胡晸煌', '1e10c1542a7eee55f6799a61b59875ff', '', '218.81.23.100', '218.81.188.185', 1584928504, 1585012600, 1, 51, 8, 3); INSERT INTO `shop_admin_user` VALUES (13, '吴辰辰', '1e10c1542a7eee55f6799a61b59875ff', '', '218.81.23.100', '218.81.188.185', 1584928439, 1585011586, 1, 45, 4, 3); INSERT INTO `shop_admin_user` VALUES (14, '张薇', '1e10c1542a7eee55f6799a61b59875ff', '', '218.81.23.100', '218.81.188.185', 1584666251, 1585012332, 1, 76, 6, 2); INSERT INTO `shop_admin_user` VALUES (15, '张屹浩', '1e10c1542a7eee55f6799a61b59875ff', '', '218.81.23.100', '218.81.188.185', 1584928594, 1585011443, 1, 36, 4, 3); INSERT INTO `shop_admin_user` VALUES (16, '郑启元', '1e10c1542a7eee55f6799a61b59875ff', '', '218.79.227.218', '218.79.227.218', 1584928760, 1585011117, 1, 38, 7, 2); INSERT INTO `shop_admin_user` VALUES (17, '季宇', '1e10c1542a7eee55f6799a61b59875ff', '', '218.81.188.185', '218.81.188.185', 1584950570, 1585009542, 1, 14, 6, 2); INSERT INTO `shop_admin_user` VALUES (18, '王虓昊', '1e10c1542a7eee55f6799a61b59875ff', '', '114.88.107.190', '114.88.107.190', 1584928451, 1585011639, 1, 16, 4, 2); -- ---------------------------- -- Table structure for theme -- ---------------------------- DROP TABLE IF EXISTS `theme`; CREATE TABLE `theme` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '专题名称', `description` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '专题描述', `topic_img_id` int(11) NOT NULL COMMENT '主题图,外键', `delete_time` int(11) DEFAULT NULL, `head_img_id` int(11) NOT NULL COMMENT '专题列表页,头图', `update_time` int(11) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 4 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '主题信息表' ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of theme -- ---------------------------- INSERT INTO `theme` VALUES (1, '专题栏位一', '美味水果世界', 16, NULL, 49, NULL); INSERT INTO `theme` VALUES (2, '专题栏位二', '新品推荐', 17, NULL, 50, NULL); INSERT INTO `theme` VALUES (3, '专题栏位三', '做个干物女', 18, NULL, 18, NULL); -- ---------------------------- -- Table structure for theme_product -- ---------------------------- DROP TABLE IF EXISTS `theme_product`; CREATE TABLE `theme_product` ( `theme_id` int(11) NOT NULL COMMENT '主题外键', `product_id` int(11) NOT NULL COMMENT '商品外键', PRIMARY KEY (`theme_id`, `product_id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '主题所包含的商品' ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of theme_product -- ---------------------------- INSERT INTO `theme_product` VALUES (1, 2); INSERT INTO `theme_product` VALUES (1, 5); INSERT INTO `theme_product` VALUES (1, 8); INSERT INTO `theme_product` VALUES (1, 10); INSERT INTO `theme_product` VALUES (1, 12); INSERT INTO `theme_product` VALUES (2, 1); INSERT INTO `theme_product` VALUES (2, 2); INSERT INTO `theme_product` VALUES (2, 3); INSERT INTO `theme_product` VALUES (2, 5); INSERT INTO `theme_product` VALUES (2, 6); INSERT INTO `theme_product` VALUES (2, 16); INSERT INTO `theme_product` VALUES (2, 33); INSERT INTO `theme_product` VALUES (3, 15); INSERT INTO `theme_product` VALUES (3, 18); INSERT INTO `theme_product` VALUES (3, 19); INSERT INTO `theme_product` VALUES (3, 27); INSERT INTO `theme_product` VALUES (3, 30); INSERT INTO `theme_product` VALUES (3, 31); -- ---------------------------- -- Table structure for third_app -- ---------------------------- DROP TABLE IF EXISTS `third_app`; CREATE TABLE `third_app` ( `id` int(11) NOT NULL AUTO_INCREMENT, `app_id` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '应用app_id', `app_secret` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '应用secret', `app_description` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '应用程序描述', `scope` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '应用权限', `scope_description` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '权限描述', `delete_time` int(11) DEFAULT NULL, `update_time` int(11) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 2 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '访问API的各应用账号密码表' ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of third_app -- ---------------------------- INSERT INTO `third_app` VALUES (1, 'starcraft', '777*777', 'CMS', '32', 'Super', NULL, NULL); -- ---------------------------- -- Table structure for user -- ---------------------------- DROP TABLE IF EXISTS `user`; CREATE TABLE `user` ( `id` int(11) NOT NULL AUTO_INCREMENT, `openid` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, `nickname` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL, `extend` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL, `delete_time` int(11) DEFAULT NULL, `create_time` int(11) DEFAULT NULL COMMENT '注册时间', `update_time` int(11) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, UNIQUE INDEX `openid`(`openid`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 3 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of user -- ---------------------------- INSERT INTO `user` VALUES (2, 'oTmIB5e7Ldrx2G8o0hAa9rlEBzR8', NULL, NULL, NULL, NULL, NULL); -- ---------------------------- -- Table structure for user_address -- ---------------------------- DROP TABLE IF EXISTS `user_address`; CREATE TABLE `user_address` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(30) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '收获人姓名', `mobile` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '手机号', `province` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '省', `city` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '市', `country` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '区', `detail` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '详细地址', `delete_time` int(11) DEFAULT NULL, `user_id` int(11) NOT NULL COMMENT '外键', `update_time` int(11) DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, UNIQUE INDEX `user_id`(`user_id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 2 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; -- ---------------------------- -- Records of user_address -- ---------------------------- INSERT INTO `user_address` VALUES (1, '刘海洋', '13382322040', '上海市', '闸北区', '永和一村', '汶水路200浩', NULL, 2, 1600244637); SET FOREIGN_KEY_CHECKS = 1;
62.377778
164
0.668685
90c06f7219eed1fde4adace5ddb930d93100c46c
2,281
lua
Lua
UI/Container/GlobalSearchContainer.lua
pngmn/tdBag2
f53be415f5680609e1fefce54d9b7cd9802bcfc9
[ "MIT" ]
4
2020-03-28T12:22:31.000Z
2022-01-25T08:40:58.000Z
UI/Container/GlobalSearchContainer.lua
pngmn/tdBag2
f53be415f5680609e1fefce54d9b7cd9802bcfc9
[ "MIT" ]
13
2019-10-25T08:58:28.000Z
2022-02-16T19:12:11.000Z
UI/Container/GlobalSearchContainer.lua
pngmn/tdBag2
f53be415f5680609e1fefce54d9b7cd9802bcfc9
[ "MIT" ]
3
2021-05-23T22:17:08.000Z
2022-01-06T03:45:37.000Z
-- GlobalSearchContainer.lua -- @Author : Dencer (tdaddon@163.com) -- @Link : https://dengsir.github.io -- @Date : 2/11/2020, 2:54:54 PM -- ---@type ns local ns = select(2, ...) local TitleContainer = ns.UI.TitleContainer ---@type tdBag2GlobalSearchContainer local GlobalSearchContainer = ns.Addon:NewClass('UI.GlobalSearchContainer', TitleContainer) GlobalSearchContainer.SEARCHING_TEMPLATE = 'tdBag2SearchingTemplate' function GlobalSearchContainer:Constructor() self.alwaysShowTitle = true self.ContentParent = CreateFrame('Frame', nil, self) self.Searching = CreateFrame('Frame', nil, self, self.SEARCHING_TEMPLATE) self.Searching:SetAllPoints(self) self.Searching:SetFrameLevel(self:GetFrameLevel() + 100) self.Searching:EnableMouse(true) self.Searching:Hide() end function GlobalSearchContainer:OnShow() TitleContainer.OnShow(self) self:RegisterEvent('GLOBAL_SEARCH_START') end function GlobalSearchContainer:GetBags() return ns.GlobalSearch:GetBags() end function GlobalSearchContainer:Layout() if not self.thread then self.thread = ns.Thread:New() self.thread:Start(self.AsyncLayout, self) end if self.thread:IsFinished() or self.thread:IsDead() then self:EndSearching() self:OnSizeChanged() self:SetScript('OnUpdate', nil) self.thread = nil else self.thread:Resume() end end function GlobalSearchContainer:AsyncLayout() self:FreeAll() self:StartSearching() self:OnLayout() end function GlobalSearchContainer:CancelLayout() if self.thread then self.thread:Kill() self.thread = nil end end function GlobalSearchContainer:Threshold() return self.thread and self.thread:Threshold() end function GlobalSearchContainer:StartSearching() self.Searching:Show() self.ContentParent:SetAlpha(0) self:SetHeight(ns.ITEM_SIZE + ns.ITEM_SPACING) self:OnSizeChanged() end function GlobalSearchContainer:EndSearching() self.Searching:Hide() self.ContentParent:SetAlpha(1) end function GlobalSearchContainer:GLOBAL_SEARCH_START() self:CancelLayout() self:StartSearching() end function GlobalSearchContainer:GLOBAL_SEARCH_UPDATE() self:CancelLayout() self:RequestLayout() end
25.344444
91
0.73345
5ff5943c4a00bc4a1eb5a87fed06e8cf15b63e72
1,117
dart
Dart
lib/harpy_widgets/theme/harpy_theme_provider.dart
sowiner/harpy
46bd4d03921041744245cd6d6f7c22bff533eff7
[ "BSD-3-Clause" ]
null
null
null
lib/harpy_widgets/theme/harpy_theme_provider.dart
sowiner/harpy
46bd4d03921041744245cd6d6f7c22bff533eff7
[ "BSD-3-Clause" ]
null
null
null
lib/harpy_widgets/theme/harpy_theme_provider.dart
sowiner/harpy
46bd4d03921041744245cd6d6f7c22bff533eff7
[ "BSD-3-Clause" ]
null
null
null
import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; import 'package:harpy/components/components.dart'; import 'package:harpy/harpy_widgets/harpy_widgets.dart'; import 'package:provider/provider.dart'; /// Provides the currently used [HarpyTheme] to its descendants. class HarpyThemeProvider extends StatelessWidget { const HarpyThemeProvider({ required this.child, }); final Widget child; @override Widget build(BuildContext context) { return ProxyProvider2<ThemeBloc, Brightness, HarpyTheme>( update: (_, themeBloc, systemBrightness, __) { final harpyTheme = systemBrightness == Brightness.light ? themeBloc.state.lightHarpyTheme : themeBloc.state.darkHarpyTheme; // match the system ui to the current theme // TODO: refactor to use a [AnnotatedRegion] instead of calling // [SystemChrome.setSystemUIOverlayStyle] manually WidgetsBinding.instance?.addPostFrameCallback((_) { updateSystemUi(harpyTheme); }); return harpyTheme; }, child: child, ); } }
31.027778
71
0.698299
7bcc3c6f0c96f7f088c6e7ba64b64fba52b5ca2c
114
rb
Ruby
features/step_definitions/shared_steps.rb
5Sigma/help_kit
928aec3b2d256699ef41deba5c4030449322fbf6
[ "MIT" ]
null
null
null
features/step_definitions/shared_steps.rb
5Sigma/help_kit
928aec3b2d256699ef41deba5c4030449322fbf6
[ "MIT" ]
null
null
null
features/step_definitions/shared_steps.rb
5Sigma/help_kit
928aec3b2d256699ef41deba5c4030449322fbf6
[ "MIT" ]
null
null
null
Then(/should see flash message "(.*)"/) do |message| expect(page).to have_selector('.flash', text: message) end
28.5
56
0.684211
7bda68be1fbeec120035c05685b7f898089c10da
4,285
css
CSS
docs/assets/css/main.css
claudiapalazon/series-finder
44a4d88949021965ae2034dc64559619d882e6e1
[ "MIT" ]
1
2020-11-07T18:34:21.000Z
2020-11-07T18:34:21.000Z
docs/assets/css/main.css
claudiapalazon/series-finder
44a4d88949021965ae2034dc64559619d882e6e1
[ "MIT" ]
null
null
null
docs/assets/css/main.css
claudiapalazon/series-finder
44a4d88949021965ae2034dc64559619d882e6e1
[ "MIT" ]
null
null
null
*{margin:0px;box-sizing:border-box}.body{background-color:black}.main{height:100vh;display:flex;flex-direction:column;justify-content:center;align-items:center;background:url("../images/cinema.jpg") no-repeat;background-position:top center;background-size:cover}.main__text{color:white}.main__form--submit{cursor:pointer}.main .main__text{font-family:"Sansita Swashed", cursive;font-size:50px;margin-bottom:30px}.main .main__form{display:flex;flex-direction:column;align-items:center}.main .main__form--input{margin-bottom:15px;height:25px;width:200px;border:0;outline:none;border-radius:4px}.main .main__form--submit{height:30px;width:200px;border:0;outline:none;border-radius:7px;color:#ffffff;background-color:crimson;box-shadow:3px 3px 15px white}.main .button-fav{display:none}.main .container-hidden{display:none}.main .js-main-containerList2{grid-template-columns:1fr}.main .js-main-containerList2 .js-main-showFav{grid-template-columns:1fr 1fr 1fr 1fr}.no-results{color:white;text-align:center;grid-column:3 / 4;margin-top:20px;margin-bottom:20px}.js-main-showList{height:100%;width:100%;background:none;background-color:black;display:inline-block;padding:10px 0px 0 20px;text-align:center}.js-main-showList .main__text{font-size:30px;margin-bottom:10px}.js-main-showList .main__form--input{margin-bottom:10px}.js-main-showList .main__form--submit{box-shadow:none}.js-main-containerList{display:grid;grid-template-columns:60% 40%;margin-right:20px}@media all and (max-width: 1200px){.js-main-containerList{display:flex;flex-direction:column;margin-right:0px}.js-main-containerList .no-results{grid-column:span 1}}.main__list{max-width:100%;height:100%;display:grid;grid-template-columns:1fr 1fr 1fr 1fr 1fr;grid-gap:15px;justify-items:center;padding:0px}@media all and (max-width: 1200px){.main__list{grid-template-columns:1fr 1fr 1fr 1fr}}.js-show-item{cursor:pointer}.js-show-item,.js-fav-item{text-align:center;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;max-width:210px;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;margin-top:20px;max-height:332px;background-color:white;border-radius:3%;overflow:hidden;box-shadow:5px 5px 15px white;position:relative}.js-show-name,.js-fav-name{font-family:"Roboto Condensed", sans-serif;font-size:20px;margin:5px}.js-show-img,.js-fav-img{transform:translate(0, 5px)}.js-show-item-favorite{box-shadow:5px 5px 15px red}.js-show-item-favorite .js-show-name{color:red}.js-main-noresults{display:flex;justify-content:center;margin-top:20px}.js-main-showListFav{grid-template-columns:1fr 1fr 1fr}@media all and (max-width: 1200px){.js-main-showListFav{grid-template-columns:1fr 1fr 1fr 1fr}}.js-main-showFav{display:grid;grid-template-columns:1fr 1fr;grid-gap:15px;justify-items:center;padding:0px}@media all and (max-width: 1200px){.js-main-showFav{grid-template-columns:1fr 1fr 1fr 1fr}}.js-main-showFav .js-fav-item{background-color:red;color:white;box-shadow:5px 5px 15px black}.js-main-containerList .container-fav{background-color:white;width:100%;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;padding:20px;border-radius:5px;margin-right:20px;margin-top:20px}.js-main-containerList .container-fav .button-fav{display:inline-block}@media all and (max-width: 1200px){.js-main-containerList .container-fav{grid-template-columns:1fr 1fr 1fr 1fr;margin-top:40px;margin-right:0px;border-radius:0px}}.heart{cursor:pointer;margin-left:3px;color:white}.js-main-showList .container-hidden{display:inline-block}.heart-favorite{background-color:white;width:50px;height:50px;color:red;position:fixed;top:15px;right:20px;font-size:30px;display:flex;justify-content:center;align-items:center;border-radius:50%;cursor:pointer}.js-main-showList .heart-favorite{display:none}.button-fav{border:none;border-radius:7px;background-color:red;color:white;height:30px;cursor:pointer}.mainFavorites{display:grid;grid-template-rows:30% 70%;height:100%;background:none;background-color:black;text-align:center}.mainFavorites .js-main-containerList{grid-template-columns:calc(100vw - 100px);grid-template-rows:10% 90%;text-align:center}.mainFavorites .js-main-containerList .container-fav{width:100%}.mainFavorites .js-main-containerList .js-main-showFav{grid-template-columns:1fr 1fr 1fr 1fr}
2,142.5
4,284
0.807001
7081a55e82b1d926a1bd6f5a37d3f74fc33bc2a0
925
go
Go
hydra/impt/impt.go
daniel-007/hydra
d3ad96ad9af271daee2ea1d4b5fc0b07815bae7d
[ "MIT" ]
null
null
null
hydra/impt/impt.go
daniel-007/hydra
d3ad96ad9af271daee2ea1d4b5fc0b07815bae7d
[ "MIT" ]
null
null
null
hydra/impt/impt.go
daniel-007/hydra
d3ad96ad9af271daee2ea1d4b5fc0b07815bae7d
[ "MIT" ]
null
null
null
// +build !oci package impt import ( _ "github.com/micro-plat/hydra/engines" _ "github.com/micro-plat/hydra/registry/local" _ "github.com/micro-plat/hydra/registry/zookeeper" _ "github.com/micro-plat/hydra/rpc" _ "github.com/micro-plat/hydra/servers/cron" _ "github.com/micro-plat/hydra/servers/http" _ "github.com/micro-plat/hydra/servers/mqc" _ "github.com/micro-plat/hydra/servers/rpc" _ "github.com/micro-plat/hydra/servers/ws" _ "github.com/micro-plat/lib4go/cache/memcache" _ "github.com/micro-plat/lib4go/cache/redis" _ "github.com/micro-plat/lib4go/mq/lmq" _ "github.com/micro-plat/lib4go/mq/mqtt" _ "github.com/micro-plat/lib4go/mq/redis" _ "github.com/micro-plat/lib4go/mq/stomp" _ "github.com/micro-plat/lib4go/mq/xmq" _ "github.com/micro-plat/lib4go/queue" _ "github.com/micro-plat/lib4go/queue/mqtt" _ "github.com/micro-plat/lib4go/queue/redis" _ "github.com/micro-plat/lib4go/queue/xmq" )
34.259259
51
0.748108
8059ee17a25eee5a43035621192abb518aaf53b2
3,770
java
Java
src/org/pepstock/charba/client/impl/charts/Threshold.java
pepstock-org/Charba
cf6964a04bf88c77019634c4d701397560392e58
[ "Apache-2.0" ]
48
2018-02-01T09:11:02.000Z
2022-03-17T12:47:01.000Z
src/org/pepstock/charba/client/impl/charts/Threshold.java
pepstock-org/Charba
cf6964a04bf88c77019634c4d701397560392e58
[ "Apache-2.0" ]
61
2018-05-03T13:38:47.000Z
2022-03-10T13:00:25.000Z
src/org/pepstock/charba/client/impl/charts/Threshold.java
pepstock-org/Charba
cf6964a04bf88c77019634c4d701397560392e58
[ "Apache-2.0" ]
7
2018-02-03T10:18:00.000Z
2021-06-18T18:16:05.000Z
/** Copyright 2017 Andrea "Stock" Stocchero Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ package org.pepstock.charba.client.impl.charts; import org.pepstock.charba.client.colors.IsColor; /** * Is the threshold to use for gauge chart. * * @author Andrea "Stock" Stocchero */ public final class Threshold implements IsThreshold { /** * Default color value, {@link DefaultThreshold#NORMAL}. */ public static final IsColor DEFAULT_VALUE_COLOR = DefaultThreshold.NORMAL.getColor(); /** * Default value, {@link java.lang.Double#MAX_VALUE}. */ private static final double DEFAULT_VALUE = Double.MAX_VALUE; private final String name; private double value = DEFAULT_VALUE; private IsColor color = DEFAULT_VALUE_COLOR; /** * Creates a threshold with standard color ({@link Threshold#DEFAULT_VALUE_COLOR}) and value ({@link java.lang.Double#MAX_VALUE}). * * @param name name of threshold */ public Threshold(String name) { this(name, DEFAULT_VALUE, DEFAULT_VALUE_COLOR); } /** * Creates a threshold with standard value ({@link java.lang.Double#MAX_VALUE}). * * @param name name of threshold * @param color color of threshold */ public Threshold(String name, IsColor color) { this(name, DEFAULT_VALUE, color); } /** * Creates a threshold with standard color ({@link Threshold#DEFAULT_VALUE_COLOR}). * * @param name name of threshold * @param value value of threshold */ public Threshold(String name, double value) { this(name, value, DEFAULT_VALUE_COLOR); } /** * Creates a threshold * * @param name name of threshold * @param value value of threshold * @param color color of threshold */ public Threshold(String name, double value, IsColor color) { this.name = name; this.value = value; this.color = color; // checks if is consistent IsThreshold.checkIfValid(this); } /* * (non-Javadoc) * * @see org.pepstock.charba.client.enums.IsThreshold#getName() */ @Override public String getName() { return name; } /* * (non-Javadoc) * * @see org.pepstock.charba.client.enums.IsThreshold#getValue() */ @Override public double getValue() { return value; } /* * (non-Javadoc) * * @see org.pepstock.charba.client.enums.IsThreshold#getColor() */ @Override public IsColor getColor() { return color; } /** * Sets the value of threshold. * * @param value the value to set * @return the threshold instance */ public Threshold setValue(double value) { this.value = value; return this; } /** * Sets the color of threshold. * * @param color the color to set * @return the threshold instance */ public Threshold setColor(IsColor color) { this.color = color; return this; } /** * Checks if the value passed is in the threshold. * * @param valueToCheck value to check * @param lowLimit the low limit * @return <code>true</code> is the value is inside the range, otherwise <code>false</code>. */ public boolean isInRange(double valueToCheck, double lowLimit) { return valueToCheck >= lowLimit && valueToCheck < getValue(); } }
24.966887
132
0.668966
be7eb024c16c45010564744044d802422762df18
9,759
sql
SQL
oc-content/languages/fr_FR/mail.sql
fossabot/Osclass
fb085fa256406e7a67cc3e4c295fed6bf8ec26d0
[ "Apache-2.0" ]
1
2020-08-05T03:34:30.000Z
2020-08-05T03:34:30.000Z
oc-content/languages/fr_FR/mail.sql
fossabot/Osclass
fb085fa256406e7a67cc3e4c295fed6bf8ec26d0
[ "Apache-2.0" ]
null
null
null
oc-content/languages/fr_FR/mail.sql
fossabot/Osclass
fb085fa256406e7a67cc3e4c295fed6bf8ec26d0
[ "Apache-2.0" ]
null
null
null
INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (1, 'fr_FR', '{WEB_TITLE} - Quelqu\'un a une question au sujet de votre annonce', '<p>Bonjour {CONTACT_NAME}!</p><p>{USER_NAME} ({USER_EMAIL}, {USER_PHONE}) vous a laissé un message au sujet de votre annonce <a href="{ITEM_URL}">{ITEM_TITLE}</a>:</p><p>{COMMENT}</p><p>Cordialement,</p><p>{WEB_TITLE}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (2, 'fr_FR', 'Merci de valider votre compte sur {WEB_TITLE}', '<p>Bonjour {USER_NAME},</p><p>Veuillez valider votre inscription en cliquant sur le lien suivant: {VALIDATION_LINK}</p><p>Merci!</p><p>Cordialement,</p><p>{WEB_TITLE}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (3, 'fr_FR', '{WEB_TITLE} - Inscription effectuée avec succès!', '<p>Hi {USER_NAME},</p><p>You\'ve successfully registered for {WEB_LINK}.</p><p>Thank you!</p><p>Regards,</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (4, 'fr_FR', 'Regarde ce que j\'ai trouvé sur {WEB_TITLE}', '<p>Bonjour {FRIEND_NAME},</p><p>Votre ami {USER_NAME} souhaite partager cette annonce avec vous:<a href="{ITEM_URL}">{ITEM_TITLE}</a></p><p>Message:</p><p>{COMMENT}</p><p>Cordialement,</p><p>{WEB_TITLE}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (5, 'fr_FR', '{WEB_TITLE} - Nouvelle annonce in the last hour', '<p>Bonjour {USER_NAME},</p><p>De nouvelles annonces ont été publiées il y a moins d\'une heure. Jetez y un coup d\'oeil :</p><p>{ADS}</p><p>-------------</p><p>Pour vous désabonner de cette alerte, cliquez ici : {UNSUB_LINK}</p><p>{WEB_TITLE}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (6, 'fr_FR', '{WEB_TITLE} - Nouvelle annonce in the last day', '<p>Bonjour {USER_NAME},</p><p>De nouvelles annonces ont été publiées il y a moins de 24h. Jetez y un oeil:</p><p>{ADS}</p><p>-------------</p><p>Pour vous désabonner de cette alerte, cliquez ici: {UNSUB_LINK}</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (7, 'fr_FR', '{WEB_TITLE} - Nouvelle annonce in the last week', '<p>Bonjour {USER_NAME},</p><p>De nouvelles annonces ont été publiées il y a moins de 7 jours. Jetez y un oeil:</p><p>{ADS}</p><p>-------------</p><p>Pour vous désabonner de cette alerte, cliquez ici: {UNSUB_LINK}</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (8, 'fr_FR', '{WEB_TITLE} - Nouvelle annonce', '<p>Bonjour {USER_NAME},</p><p>Une nouvelle annonce vient d’être publiée, jetez-y un oeil:</p><p>{ADS}</p><p>-------------</p><p>Vous recevez cet email automatique car vous êtes abonné à une alerte qui vous tient au courant des nouvelles annonces publiées. Pour vous désabonner de cette alerte, cliquez ici: {UNSUB_LINK}</p><p>{WEB_TITLE}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (9, 'fr_FR', '{WEB_TITLE} - Il y a un nouveau commentaire à propos de votre annonce', '<p>Someone commented on the listing <a href="{ITEM_URL}">{ITEM_TITLE}</a>.</p><p>Commenter: {COMMENT_AUTHOR}<br />Commenter\'s email: {COMMENT_EMAIL}<br />Title: {COMMENT_TITLE}<br />Comment: {COMMENT_TEXT}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (10, 'fr_FR', '{WEB_TITLE} - Gestion de votre annonce {ITEM_TITLE}', '<p>Hi {USER_NAME},</p><p>You\'re not registered at {WEB_LINK}, but you can still edit or delete the listing <a href="{ITEM_URL}">{ITEM_TITLE}</a> for a short period of time.</p><p>You can edit your listing by following this link: {EDIT_LINK}</p><p>You can delete your listing by following this link: {DELETE_LINK}</p><p>If you register as a user, you will have full access to editing options.</p><p>Regards,</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (11, 'fr_FR', '{WEB_TITLE} - Validez votre annonce', '<p>Hi {USER_NAME},</p><p>You\'re receiving this e-mail because a listing has been published at {WEB_LINK}. Please validate this listing by clicking on the following link: {VALIDATION_LINK}. If you didn\'t publish this listing, please ignore this email.</p><p>Listing details:</p><p>Contact name: {USER_NAME}<br />Contact e-mail: {USER_EMAIL}</p><p>{ITEM_DESCRIPTION}</p><p>Url: {ITEM_URL}</p><p>Regards,</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (12, 'fr_FR', '{WEB_TITLE} - Votre alerte: une nouvelle annonce a été publiée', '<p>Dear {WEB_TITLE} admin,</p><p>You\'re receiving this email because a listing has been published at {WEB_LINK}.</p><p>Listing details:</p><p>Contact name: {USER_NAME}<br />Contact email: {USER_EMAIL}</p><p>{ITEM_DESCRIPTION}</p><p>Url: {ITEM_URL}</p><p>You can edit this listing by clicking on the following link: {EDIT_LINK}</p><p>Regards,</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (13, 'fr_FR', '{WEB_TITLE} - Récupération de votre mot de passe', '<p>Hi {USER_NAME},</p><p>We\'ve sent you this e-mail because you\'ve requested a password reminder. Follow this link to recover it: {PASSWORD_LINK}</p><p>The link will be deactivated in 24 hours.</p><p>If you didn\'t request a password reminder, please ignore this message. This request was made from IP {IP_ADDRESS} on {DATE_TIME}</p><p>Regards,</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (14, 'fr_FR', '{WEB_TITLE} - Vous avez demandé un changement d\'adresse e-mail', '<p>Hi {USER_NAME}</p><p>You\'re receiving this e-mail because you requested an e-mail change. Please confirm this new e-mail address by clicking on the following validation link: {VALIDATION_LINK}</p><p>Regards,</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (15, 'fr_FR', '{WEB_TITLE} - Merci de valider votre alerte', '<p>Bonjour {USER_NAME},</p><p>Veuillez svp confirmer votre inscription à cette alerte en cliquant sur le lien suivant:{VALIDATION_LINK}</p><p>Merci</p><p>Cordialement,</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (16, 'fr_FR', '{WEB_TITLE} - Votre commentaire a été accepté', '<p>Bonjour {COMMENT_AUTHOR},</p><p>Votre commentaire à propos de <a href="{ITEM_URL}">{ITEM_TITLE}</a> a été approuvé.</p><p>Salutations,</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (17, 'fr_FR', '{WEB_TITLE} - Validez votre annonce', '<p>Hi {USER_NAME},</p><p>You\'re receiving this e-mail because you\’ve published a listing at {WEB_LINK}. Please validate this listing by clicking on the following link: {VALIDATION_LINK}. If you didn\'t publish this listing, please ignore this e-mail.</p><p>Listing details:</p><p>Contact name: {USER_NAME}<br />Contact e-mail: {USER_EMAIL}</p><p>{ITEM_DESCRIPTION}</p><p>Url: {ITEM_URL}</p><p>Even if you\'re not registered at {WEB_LINK}, you can still edit or delete your listing:</p><p>You can edit your listing by following this link: {EDIT_LINK}</p><p>You can delete your listing by following this link: {DELETE_LINK}</p><p>Regards,</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (18, 'fr_FR', '{WEB_TITLE} - Un nouvel utilisateur vient de s\'inscrire', '<p>Dear {WEB_TITLE} admin,</p><p>You\'re receiving this email because a new user has been created at {WEB_LINK}.</p><p>User details:</p><p>Name: {USER_NAME}<br />E-mail: {USER_EMAIL}</p><p>Regards,</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (19, 'fr_FR', '{WEB_TITLE} - Vous avez été contacté. Une question vous attend.', '<p>Bonjour {CONTACT_NAME}!</p><p>{USER_NAME} ({USER_EMAIL}, {USER_PHONE}) vous a laissé un message:</p><p>{COMMENT}</p><p>Cordialement,</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (20, 'fr_FR', '{WEB_TITLE} - Un nouveau commentaire vient d\'être fait au sujet de votre annonce', '<p>There\'s a new comment on the listing: <a href="{ITEM_URL}">{ITEM_TITLE}</a>.</p><p>Author: {COMMENT_AUTHOR}<br />Author\'s email: {COMMENT_EMAIL}<br />Title: {COMMENT_TITLE}<br />Comment: {COMMENT_TEXT}</p><p>{WEB_LINK}</p>'); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (21, 'fr_FR', '{WEB_TITLE} Création du compte Administrateur réussie', '<p>Salut {ADMIN_NAME},</p><p>L\'Administrateur de {WEB_LINK} vous a créé votre compte</p><ul><li>Nom d\'utilisateur: {USERNAME}</li><li>Mot de passe: {PASSWORD}</li></ul><p>Vous pouvez accéder au tableau de bord ici: {WEB_ADMIN_LINK}.</p><p>Merci</p><p>Meilleures Salutations,</p> '); INSERT INTO /*TABLE_PREFIX*/t_pages_description (fk_i_pages_id, fk_c_locale_code, s_title, s_text) VALUES (22, 'fr_FR', '{WEB_TITLE} Votre annonce est sur le point d\'expirer!', '<p>Bonjour {USER_NAME},</p><p>Votre annonce <a href="{ITEM_URL}">{ITEM_TITLE}</a> sur {WEB_LINK} va bientôt expirer. ');
424.304348
822
0.726099
7fea8d41781110391ba33c10465637570eb5bdf1
914
rs
Rust
tests/remove_table.rs
faizol/reshape
8b6c817b30c12944eb3eeb4ff1d8d0a1a23656e1
[ "MIT" ]
1,189
2021-12-21T15:32:25.000Z
2022-03-31T01:46:42.000Z
tests/remove_table.rs
faizol/reshape
8b6c817b30c12944eb3eeb4ff1d8d0a1a23656e1
[ "MIT" ]
10
2022-01-12T20:07:27.000Z
2022-02-11T15:09:56.000Z
tests/remove_table.rs
faizol/reshape
8b6c817b30c12944eb3eeb4ff1d8d0a1a23656e1
[ "MIT" ]
22
2022-01-07T11:23:24.000Z
2022-03-27T16:59:41.000Z
mod common; use common::Test; #[test] fn remove_table() { let mut test = Test::new("Remove table"); test.first_migration( r#" name = "create_users_table" [[actions]] type = "create_table" name = "users" primary_key = ["id"] [[actions.columns]] name = "id" type = "INTEGER" "#, ); test.second_migration( r#" name = "remove_users_table" [[actions]] type = "remove_table" table = "users" "#, ); test.intermediate(|old_db, new_db| { // Make sure inserts work against the old schema old_db .simple_query("INSERT INTO users(id) VALUES (1)") .unwrap(); // Ensure the table is not accessible through the new schema assert!(new_db.query("SELECT id FROM users", &[]).is_err()); }); }
21.255814
68
0.507659
41bfc34ce4789931dba07433860fe421bb7defe4
4,518
c
C
mini_settings_set.c
batocera-linux/mini_settings
b9822f8f8aaafbc46cf9123f3b3e10d9b0d523ac
[ "MIT" ]
1
2021-01-04T12:14:57.000Z
2021-01-04T12:14:57.000Z
mini_settings_set.c
batocera-linux/mini_settings
b9822f8f8aaafbc46cf9123f3b3e10d9b0d523ac
[ "MIT" ]
1
2021-04-24T14:24:52.000Z
2021-06-18T18:07:19.000Z
mini_settings_set.c
batocera-linux/mini_settings
b9822f8f8aaafbc46cf9123f3b3e10d9b0d523ac
[ "MIT" ]
1
2020-12-23T12:16:03.000Z
2020-12-23T12:16:03.000Z
#include "mini_settings_set.h" #include <stdbool.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include "mini_settings_ascii.h" #include "mini_settings_stringbuf.h" static const size_t NOT_FOUND = -1; static size_t find_kv(const char *kvs[], size_t kvs_size, const size_t kvs_sizes[], const char *key_begin, const char *key_end) { const size_t target_key_size = key_end - key_begin; for (size_t i = 0; i < kvs_size; i += 2) { if (target_key_size == kvs_sizes[i] && memcmp(key_begin, kvs[i], target_key_size) == 0) { return i; } } return NOT_FOUND; } static void write_kv(struct mini_settings_stringbuf *out, const char *key, size_t key_size, const char *value, size_t value_size) { mini_settings_stringbuf_append(out, key, key_size); mini_settings_stringbuf_append_char(out, '='); mini_settings_stringbuf_append_line(out, value, value_size); } static struct mini_settings_set_result_t mini_settings_set_sized( const char *config_contents, size_t config_contents_size, const char *kvs[], size_t kvs_size, const size_t kvs_sizes[], bool validate) { struct mini_settings_set_result_t result; memset(&result, 0, sizeof(result)); bool *written = calloc(kvs_size / 2, sizeof(bool)); struct mini_settings_stringbuf out; mini_settings_stringbuf_init(&out, config_contents_size); const char *eof = config_contents + config_contents_size; config_contents = skip_utf8_bom(config_contents, eof); const char *line_end = config_contents - 1; size_t line_num = 0; while (line_end < eof) { ++line_num; const char *line_begin = line_end + 1; line_end = memchr(line_begin, '\n', eof - line_begin); if (line_end == NULL) { if (line_begin == eof) break; line_end = eof; } const char *key_begin = skip_leading_whitespace(line_begin, line_end); if (key_begin == line_end) { mini_settings_stringbuf_append_line(&out, line_begin, line_end - line_begin); continue; } const bool commented = *key_begin == '#'; if (commented) { ++key_begin; key_begin = skip_leading_whitespace(key_begin, line_end); } if (key_begin == line_end) { mini_settings_stringbuf_append_line(&out, line_begin, line_end - line_begin); continue; } const char *eq_pos = memchr(key_begin, '=', line_end - key_begin); if (eq_pos == NULL) { if (commented || !validate) { mini_settings_stringbuf_append_line(&out, line_begin, line_end - line_begin); continue; } const size_t err_size = 128 + (line_end - line_begin); result.error = malloc(err_size); result.error_size = snprintf(result.error, err_size, "Invalid config file: key '%.*s' has no value on line %zu", (int)(line_end - line_begin), line_begin, line_num); free(out.data); free(written); return result; } const char *key_end = skip_trailing_whitespace(key_begin, eq_pos); const size_t i = find_kv(kvs, kvs_size, kvs_sizes, key_begin, key_end); if (i == NOT_FOUND) { mini_settings_stringbuf_append_line(&out, line_begin, line_end - line_begin); continue; } write_kv(&out, kvs[i], kvs_sizes[i], kvs[i + 1], kvs_sizes[i + 1]); written[i / 2] = true; } for (size_t i = 0; i < kvs_size; i += 2) { if (!written[i / 2]) { write_kv(&out, kvs[i], kvs_sizes[i], kvs[i + 1], kvs_sizes[i + 1]); } } result.contents = out.data; result.contents_size = out.size; free(written); return result; } struct mini_settings_set_result_t mini_settings_set(const char *config_contents, size_t config_contents_size, const char *kvs[], size_t kvs_size, bool validate) { size_t *kvs_sizes = malloc(sizeof(size_t) * kvs_size); for (size_t i = 0; i < kvs_size; ++i) kvs_sizes[i] = strlen(kvs[i]); struct mini_settings_set_result_t result = mini_settings_set_sized(config_contents, config_contents_size, kvs, kvs_size, kvs_sizes, validate); free(kvs_sizes); return result; }
34.48855
80
0.610004
582411f83e2609e61a4ebb7c35fe08c1bc8dfbdd
1,696
sql
SQL
public/model_config/DMS_DB_Sql/cbdms/helper_charge_code.sql
PNNL-Comp-Mass-Spec/DMS-Website
5d81089573f6d74eaa014a1a5fe5ba55a736d259
[ "Apache-2.0" ]
null
null
null
public/model_config/DMS_DB_Sql/cbdms/helper_charge_code.sql
PNNL-Comp-Mass-Spec/DMS-Website
5d81089573f6d74eaa014a1a5fe5ba55a736d259
[ "Apache-2.0" ]
null
null
null
public/model_config/DMS_DB_Sql/cbdms/helper_charge_code.sql
PNNL-Comp-Mass-Spec/DMS-Website
5d81089573f6d74eaa014a1a5fe5ba55a736d259
[ "Apache-2.0" ]
null
null
null
PRAGMA foreign_keys=OFF; BEGIN TRANSACTION; CREATE TABLE general_params ( "name" text, "value" text ); INSERT INTO "general_params" VALUES('list_report_data_table','V_Helper_Charge_Code'); INSERT INTO "general_params" VALUES('list_report_helper_multiple_selection','no'); INSERT INTO "general_params" VALUES('list_report_data_sort_col','SortKey'); INSERT INTO "general_params" VALUES('list_report_data_sort_dir','ASC'); CREATE TABLE list_report_hotlinks ( id INTEGER PRIMARY KEY, "name" text, "LinkType" text, "WhichArg" text, "Target" text, "Options" text ); INSERT INTO "list_report_hotlinks" VALUES(1,'Charge_Code','update_opener','value','',''); INSERT INTO "list_report_hotlinks" VALUES(2,'State','color_label','#Activation_State','','{"0":"clr_30","1":"clr_45","2":"clr_60", "3":"clr_120","4":"clr_120","5":"clr_120"}'); CREATE TABLE list_report_primary_filter ( id INTEGER PRIMARY KEY, "name" text, "label" text, "size" text, "value" text, "col" text, "cmp" text, "type" text, "maxlength" text, "rows" text, "cols" text ); INSERT INTO "list_report_primary_filter" VALUES(1,'pf_charge_code','Charge_Code','20','','Charge_Code','ContainsText','text','20','',''); INSERT INTO "list_report_primary_filter" VALUES(2,'pf_wbs','WBS','20','','WBS','ContainsText','text','60','',''); INSERT INTO "list_report_primary_filter" VALUES(3,'pf_title','Title','20','','Title','ContainsText','text','30','',''); INSERT INTO "list_report_primary_filter" VALUES(4,'pf_subaccount','SubAccount','20','','SubAccount','ContainsText','text','60','',''); INSERT INTO "list_report_primary_filter" VALUES(5,'pf_owner_name','Owner','20','','Owner_Name','ContainsText','text','50','',''); COMMIT;
89.263158
204
0.714623
4fb0e4bdae2e04fd19785e776b5d2d95936469ce
1,234
lua
Lua
lua/tender/colors.lua
lanej/tender
2aa6d7c0c6549ac2430d64f0518e3104709b3dc3
[ "MIT" ]
null
null
null
lua/tender/colors.lua
lanej/tender
2aa6d7c0c6549ac2430d64f0518e3104709b3dc3
[ "MIT" ]
null
null
null
lua/tender/colors.lua
lanej/tender
2aa6d7c0c6549ac2430d64f0518e3104709b3dc3
[ "MIT" ]
null
null
null
local lush = require("lush") local hsl = lush.hsl local colors = {} colors = { bg = hsl("#282828"), blue = hsl("#b3deef"), blue1 = hsl("#b3deef"), blue2 = hsl("#73cef4"), blue3 = hsl("#44778d"), blue4 = hsl("#335261"), cyan = hsl("#7dcfff"), darker = hsl("#1d1d1d"), darkest = hsl("#040404"), gandalf = hsl("#bbbbbb"), green = hsl("#c9d05c"), green1 = hsl("#c9d05c"), green2 = hsl("#9faa00"), green3 = hsl("#6a6b3f"), green4 = hsl("#464632"), grey = hsl("#999999"), grey1 = hsl("#999999"), grey2 = hsl("#666666"), grey3 = hsl("#444444"), highlighted = hsl("#ffffff"), red = hsl("#f43753"), red1 = hsl("#f43753"), red2 = hsl("#c5152f"), red3 = hsl("#79313c"), shadow = hsl("#323232"), teal = hsl("#1abc9c"), fg = hsl("#eeeeee"), normal = hsl("#eeeeee"), orange = hsl("#ff8000"), yellow = hsl("#d3b987"), yellow1 = hsl("#d3b987"), yellow2 = hsl("#ffc24b"), yellow3 = hsl("#715b2f"), purple = hsl("#a866ff"), purple1 = hsl("#a866ff"), purple2 = hsl("#6e00ff"), purple3 = hsl("#400094"), magenta = hsl("#bb9af7"), magenta2 = hsl("#ff007c"), diff = { add = hsl("#c9d05c"), change = hsl("#ff8000"), delete = hsl("#f43753"), }, } return colors
22.851852
31
0.549433
7d7ff57f21297c0f5a0a2f1fc2aa50dfa189dbd7
28,276
html
HTML
documentation/doxygen/io_8h.html
kmuseth/openvdb-website
454c06278acd77e4bc294efc2c4b9565da7d992d
[ "CC-BY-4.0" ]
10
2019-01-25T20:10:25.000Z
2022-03-27T21:21:29.000Z
documentation/doxygen/io_8h.html
kmuseth/openvdb-website
454c06278acd77e4bc294efc2c4b9565da7d992d
[ "CC-BY-4.0" ]
10
2019-10-08T22:22:17.000Z
2021-04-22T22:37:35.000Z
documentation/doxygen/io_8h.html
kmuseth/openvdb-website
454c06278acd77e4bc294efc2c4b9565da7d992d
[ "CC-BY-4.0" ]
13
2018-12-11T18:50:44.000Z
2021-07-22T21:21:01.000Z
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <meta http-equiv="X-UA-Compatible" content="IE=9"/> <meta name="generator" content="Doxygen 1.8.11"/> <title>OpenVDB: io.h File Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="jquery.js"></script> <script type="text/javascript" src="dynsections.js"></script> <link href="search/search.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="search/searchdata.js"></script> <script type="text/javascript" src="search/search.js"></script> <script type="text/javascript"> $(document).ready(function() { init_search(); }); </script> <link href="doxygen.css" rel="stylesheet" type="text/css" /> </head> <body> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td id="projectalign" style="padding-left: 0.5em;"> <div id="projectname">OpenVDB &#160;<span id="projectnumber">8.0.1</span> </div> </td> </tr> </tbody> </table> </div> <!-- end header part --> <!-- Generated by Doxygen 1.8.11 --> <script type="text/javascript"> var searchBox = new SearchBox("searchBox", "search",false,'Search'); </script> <div id="navrow1" class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main&#160;Page</span></a></li> <li><a href="pages.html"><span>Related&#160;Pages</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li><a href="annotated.html"><span>Classes</span></a></li> <li class="current"><a href="files.html"><span>Files</span></a></li> <li> <div id="MSearchBox" class="MSearchBoxInactive"> <span class="left"> <img id="MSearchSelect" src="search/mag_sel.png" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" alt=""/> <input type="text" id="MSearchField" value="Search" accesskey="S" onfocus="searchBox.OnSearchFieldFocus(true)" onblur="searchBox.OnSearchFieldFocus(false)" onkeyup="searchBox.OnSearchFieldChange(event)"/> </span><span class="right"> <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a> </span> </div> </li> </ul> </div> <div id="navrow2" class="tabs2"> <ul class="tablist"> <li><a href="files.html"><span>File&#160;List</span></a></li> <li><a href="globals.html"><span>File&#160;Members</span></a></li> </ul> </div> <!-- window showing the filter options --> <div id="MSearchSelectWindow" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" onkeydown="return searchBox.OnSearchSelectKey(event)"> </div> <!-- iframe showing the search results (closed by default) --> <div id="MSearchResultsWindow"> <iframe src="javascript:void(0)" frameborder="0" name="MSearchResults" id="MSearchResults"> </iframe> </div> <div id="nav-path" class="navpath"> <ul> <li class="navelem"><a class="el" href="dir_280f52b45faa7feb3f4c229d1d8418c8.html">openvdb</a></li><li class="navelem"><a class="el" href="dir_5862e09d5e9b1231151ba919eed3a485.html">openvdb</a></li><li class="navelem"><a class="el" href="dir_38eacf7399aeea68b81e3e6a9f9aa3a4.html">io</a></li> </ul> </div> </div><!-- top --> <div class="header"> <div class="summary"> <a href="#nested-classes">Classes</a> &#124; <a href="#namespaces">Namespaces</a> &#124; <a href="#func-members">Functions</a> </div> <div class="headertitle"> <div class="title">io.h File Reference</div> </div> </div><!--header--> <div class="contents"> <div class="textblock"><code>#include &lt;<a class="el" href="Platform_8h_source.html">openvdb/Platform.h</a>&gt;</code><br /> <code>#include &lt;<a class="el" href="openvdb_2Types_8h_source.html">openvdb/Types.h</a>&gt;</code><br /> <code>#include &lt;<a class="el" href="version_8h_source.html">openvdb/version.h</a>&gt;</code><br /> <code>#include &lt;boost/any.hpp&gt;</code><br /> <code>#include &lt;functional&gt;</code><br /> <code>#include &lt;iosfwd&gt;</code><br /> <code>#include &lt;map&gt;</code><br /> <code>#include &lt;memory&gt;</code><br /> <code>#include &lt;string&gt;</code><br /> </div> <p><a href="io_8h_source.html">Go to the source code of this file.</a></p> <table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a> Classes</h2></td></tr> <tr class="memitem:"><td class="memItemLeft" align="right" valign="top">class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classopenvdb_1_1v8__0_1_1io_1_1StreamMetadata.html">StreamMetadata</a></td></tr> <tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Container for metadata describing how to unserialize grids from and/or serialize grids to a stream (which file format, compression scheme, etc. to use) <a href="classopenvdb_1_1v8__0_1_1io_1_1StreamMetadata.html#details">More...</a><br /></td></tr> <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structopenvdb_1_1v8__0_1_1io_1_1MultiPass.html">MultiPass</a></td></tr> <tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Leaf nodes that require multi-pass I/O must inherit from this struct. <a href="structopenvdb_1_1v8__0_1_1io_1_1MultiPass.html#details">More...</a><br /></td></tr> <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:"><td class="memItemLeft" align="right" valign="top">class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classopenvdb_1_1v8__0_1_1io_1_1MappedFile.html">MappedFile</a></td></tr> <tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Handle to control the lifetime of a memory-mapped .vdb file. <a href="classopenvdb_1_1v8__0_1_1io_1_1MappedFile.html#details">More...</a><br /></td></tr> <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr> </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="namespaces"></a> Namespaces</h2></td></tr> <tr class="memitem:namespaceopenvdb"><td class="memItemLeft" align="right" valign="top"> &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb.html">openvdb</a></td></tr> <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:namespaceopenvdb_1_1v8__0"><td class="memItemLeft" align="right" valign="top"> &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0.html">openvdb::v8_0</a></td></tr> <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:namespaceopenvdb_1_1v8__0_1_1io"><td class="memItemLeft" align="right" valign="top"> &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html">openvdb::v8_0::io</a></td></tr> <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr> </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a> Functions</h2></td></tr> <tr class="memitem:a83d44cf9147c9833f5a489f25d10e521"><td class="memItemLeft" align="right" valign="top">std::ostream &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a83d44cf9147c9833f5a489f25d10e521">operator&lt;&lt;</a> (std::ostream &amp;, const StreamMetadata &amp;)</td></tr> <tr class="memdesc:a83d44cf9147c9833f5a489f25d10e521"><td class="mdescLeft">&#160;</td><td class="mdescRight">Write a description of the given metadata to an output stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a83d44cf9147c9833f5a489f25d10e521">More...</a><br /></td></tr> <tr class="separator:a83d44cf9147c9833f5a489f25d10e521"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:aeb9c3a989a51435d7ab08f1144c8a028"><td class="memItemLeft" align="right" valign="top">std::ostream &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#aeb9c3a989a51435d7ab08f1144c8a028">operator&lt;&lt;</a> (std::ostream &amp;, const StreamMetadata::AuxDataMap &amp;)</td></tr> <tr class="separator:aeb9c3a989a51435d7ab08f1144c8a028"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:aa6416602e90fa84c58d1ec5526dd974e"><td class="memItemLeft" align="right" valign="top">std::string&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#aa6416602e90fa84c58d1ec5526dd974e">getErrorString</a> (int errorNum)</td></tr> <tr class="memdesc:aa6416602e90fa84c58d1ec5526dd974e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return a string (possibly empty) describing the given system error code. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#aa6416602e90fa84c58d1ec5526dd974e">More...</a><br /></td></tr> <tr class="separator:aa6416602e90fa84c58d1ec5526dd974e"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a1436b22cdd1c6811b144b93be9a1b123"><td class="memItemLeft" align="right" valign="top">std::string&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a1436b22cdd1c6811b144b93be9a1b123">getErrorString</a> ()</td></tr> <tr class="memdesc:a1436b22cdd1c6811b144b93be9a1b123"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return a string (possibly empty) describing the most recent system error. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a1436b22cdd1c6811b144b93be9a1b123">More...</a><br /></td></tr> <tr class="separator:a1436b22cdd1c6811b144b93be9a1b123"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a3115b2f352ffd78fa41eba0a53d48940"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a3115b2f352ffd78fa41eba0a53d48940">getFormatVersion</a> (std::ios_base &amp;)</td></tr> <tr class="memdesc:a3115b2f352ffd78fa41eba0a53d48940"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the file format version number associated with the given input stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a3115b2f352ffd78fa41eba0a53d48940">More...</a><br /></td></tr> <tr class="separator:a3115b2f352ffd78fa41eba0a53d48940"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:ad770b10b4a16dbbded53191971139de3"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> VersionId&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#ad770b10b4a16dbbded53191971139de3">getLibraryVersion</a> (std::ios_base &amp;)</td></tr> <tr class="memdesc:ad770b10b4a16dbbded53191971139de3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the (major, minor) library version number associated with the given input stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#ad770b10b4a16dbbded53191971139de3">More...</a><br /></td></tr> <tr class="separator:ad770b10b4a16dbbded53191971139de3"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a32d5a6c2c2756f230f1ebd830b526de4"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> std::string&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a32d5a6c2c2756f230f1ebd830b526de4">getVersion</a> (std::ios_base &amp;)</td></tr> <tr class="memdesc:a32d5a6c2c2756f230f1ebd830b526de4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return a string of the form "&lt;major&gt;.&lt;minor&gt;/&lt;format&gt;", giving the library and file format version numbers associated with the given input stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a32d5a6c2c2756f230f1ebd830b526de4">More...</a><br /></td></tr> <tr class="separator:a32d5a6c2c2756f230f1ebd830b526de4"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:affe430ab8e3f428c61ef1d73271ca751"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#affe430ab8e3f428c61ef1d73271ca751">setCurrentVersion</a> (std::istream &amp;)</td></tr> <tr class="memdesc:affe430ab8e3f428c61ef1d73271ca751"><td class="mdescLeft">&#160;</td><td class="mdescRight">Associate the current file format and library version numbers with the given input stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#affe430ab8e3f428c61ef1d73271ca751">More...</a><br /></td></tr> <tr class="separator:affe430ab8e3f428c61ef1d73271ca751"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a5ff35c2a5783cbbdd992e517c1361f6a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a5ff35c2a5783cbbdd992e517c1361f6a">setVersion</a> (std::ios_base &amp;, const VersionId &amp;libraryVersion, uint32_t fileVersion)</td></tr> <tr class="memdesc:a5ff35c2a5783cbbdd992e517c1361f6a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Associate specific file format and library version numbers with the given stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a5ff35c2a5783cbbdd992e517c1361f6a">More...</a><br /></td></tr> <tr class="separator:a5ff35c2a5783cbbdd992e517c1361f6a"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a2225c0f9a83bf214cc9e8849ef0a844e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a2225c0f9a83bf214cc9e8849ef0a844e">getDataCompression</a> (std::ios_base &amp;)</td></tr> <tr class="memdesc:a2225c0f9a83bf214cc9e8849ef0a844e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return a bitwise OR of compression option flags (COMPRESS_ZIP, COMPRESS_ACTIVE_MASK, etc.) specifying whether and how input data is compressed or output data should be compressed. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a2225c0f9a83bf214cc9e8849ef0a844e">More...</a><br /></td></tr> <tr class="separator:a2225c0f9a83bf214cc9e8849ef0a844e"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a802ad92bd384625a60e6ee247c1b9516"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a802ad92bd384625a60e6ee247c1b9516">setDataCompression</a> (std::ios_base &amp;, uint32_t compressionFlags)</td></tr> <tr class="memdesc:a802ad92bd384625a60e6ee247c1b9516"><td class="mdescLeft">&#160;</td><td class="mdescRight">Associate with the given stream a bitwise OR of compression option flags (COMPRESS_ZIP, COMPRESS_ACTIVE_MASK, etc.) specifying whether and how input data is compressed or output data should be compressed. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a802ad92bd384625a60e6ee247c1b9516">More...</a><br /></td></tr> <tr class="separator:a802ad92bd384625a60e6ee247c1b9516"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a987107f23f746f49f3c60b53547c6b58"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a987107f23f746f49f3c60b53547c6b58">getGridClass</a> (std::ios_base &amp;)</td></tr> <tr class="memdesc:a987107f23f746f49f3c60b53547c6b58"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the class (GRID_LEVEL_SET, GRID_UNKNOWN, etc.) of the grid currently being read from or written to the given stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a987107f23f746f49f3c60b53547c6b58">More...</a><br /></td></tr> <tr class="separator:a987107f23f746f49f3c60b53547c6b58"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a20b1f182f3829be0f33621bdf5532fe9"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a20b1f182f3829be0f33621bdf5532fe9">setGridClass</a> (std::ios_base &amp;, uint32_t)</td></tr> <tr class="memdesc:a20b1f182f3829be0f33621bdf5532fe9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Associate with the given stream the class (GRID_LEVEL_SET, GRID_UNKNOWN, etc.) of the grid currently being read or written. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a20b1f182f3829be0f33621bdf5532fe9">More...</a><br /></td></tr> <tr class="separator:a20b1f182f3829be0f33621bdf5532fe9"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a276ec26f8e28c8023f460322232833d3"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a276ec26f8e28c8023f460322232833d3">getHalfFloat</a> (std::ios_base &amp;)</td></tr> <tr class="memdesc:a276ec26f8e28c8023f460322232833d3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return true if floating-point values should be quantized to 16 bits when writing to the given stream or promoted back from 16-bit to full precision when reading from it. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a276ec26f8e28c8023f460322232833d3">More...</a><br /></td></tr> <tr class="separator:a276ec26f8e28c8023f460322232833d3"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a00265bc16aad868355aa85556b92e413"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a00265bc16aad868355aa85556b92e413">setHalfFloat</a> (std::ios_base &amp;, bool)</td></tr> <tr class="memdesc:a00265bc16aad868355aa85556b92e413"><td class="mdescLeft">&#160;</td><td class="mdescRight">Specify whether floating-point values should be quantized to 16 bits when writing to the given stream or promoted back from 16-bit to full precision when reading from it. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a00265bc16aad868355aa85556b92e413">More...</a><br /></td></tr> <tr class="separator:a00265bc16aad868355aa85556b92e413"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a2f3554d3198b4bb67524f990cfe02286"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> const void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a2f3554d3198b4bb67524f990cfe02286">getGridBackgroundValuePtr</a> (std::ios_base &amp;)</td></tr> <tr class="memdesc:a2f3554d3198b4bb67524f990cfe02286"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return a pointer to the background value of the grid currently being read from or written to the given stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a2f3554d3198b4bb67524f990cfe02286">More...</a><br /></td></tr> <tr class="separator:a2f3554d3198b4bb67524f990cfe02286"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:ae1302a229d271b8e332723c415edb90b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#ae1302a229d271b8e332723c415edb90b">setGridBackgroundValuePtr</a> (std::ios_base &amp;, const void *background)</td></tr> <tr class="memdesc:ae1302a229d271b8e332723c415edb90b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Specify (a pointer to) the background value of the grid currently being read from or written to the given stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#ae1302a229d271b8e332723c415edb90b">More...</a><br /></td></tr> <tr class="separator:ae1302a229d271b8e332723c415edb90b"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a0f998362fd85c3d11b0e0589b3f6e2dd"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a0f998362fd85c3d11b0e0589b3f6e2dd">getWriteGridStatsMetadata</a> (std::ios_base &amp;)</td></tr> <tr class="memdesc:a0f998362fd85c3d11b0e0589b3f6e2dd"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return <code>true</code> if grid statistics (active voxel count and bounding box, etc.) should be computed and stored as grid metadata when writing to the given stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a0f998362fd85c3d11b0e0589b3f6e2dd">More...</a><br /></td></tr> <tr class="separator:a0f998362fd85c3d11b0e0589b3f6e2dd"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a1f0d63162633e8c9d6623018ac0ef234"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a1f0d63162633e8c9d6623018ac0ef234">setWriteGridStatsMetadata</a> (std::ios_base &amp;, bool writeGridStats)</td></tr> <tr class="memdesc:a1f0d63162633e8c9d6623018ac0ef234"><td class="mdescLeft">&#160;</td><td class="mdescRight">Specify whether to compute grid statistics (active voxel count and bounding box, etc.) and store them as grid metadata when writing to the given stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a1f0d63162633e8c9d6623018ac0ef234">More...</a><br /></td></tr> <tr class="separator:a1f0d63162633e8c9d6623018ac0ef234"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a497728d4e65c8ffbfe5ffd389aa3d047"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> SharedPtr&lt; MappedFile &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a497728d4e65c8ffbfe5ffd389aa3d047">getMappedFilePtr</a> (std::ios_base &amp;)</td></tr> <tr class="memdesc:a497728d4e65c8ffbfe5ffd389aa3d047"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return a shared pointer to the memory-mapped file with which the given stream is associated, or a null pointer if the stream is not associated with a memory-mapped file. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a497728d4e65c8ffbfe5ffd389aa3d047">More...</a><br /></td></tr> <tr class="separator:a497728d4e65c8ffbfe5ffd389aa3d047"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a2c123286e051343b5cd56d2232d7bcee"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a2c123286e051343b5cd56d2232d7bcee">setMappedFilePtr</a> (std::ios_base &amp;, SharedPtr&lt; MappedFile &gt; &amp;)</td></tr> <tr class="memdesc:a2c123286e051343b5cd56d2232d7bcee"><td class="mdescLeft">&#160;</td><td class="mdescRight">Associate the given stream with (a shared pointer to) a memory-mapped file. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a2c123286e051343b5cd56d2232d7bcee">More...</a><br /></td></tr> <tr class="separator:a2c123286e051343b5cd56d2232d7bcee"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a2af1df908240aff0133f5842a76c4070"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> SharedPtr&lt; StreamMetadata &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a2af1df908240aff0133f5842a76c4070">getStreamMetadataPtr</a> (std::ios_base &amp;)</td></tr> <tr class="memdesc:a2af1df908240aff0133f5842a76c4070"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return a shared pointer to an object that stores metadata (file format, compression scheme, etc.) for use when reading from or writing to the given stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a2af1df908240aff0133f5842a76c4070">More...</a><br /></td></tr> <tr class="separator:a2af1df908240aff0133f5842a76c4070"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:ace6154e2dd4418cc456e5f17a8c46f1d"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#ace6154e2dd4418cc456e5f17a8c46f1d">setStreamMetadataPtr</a> (std::ios_base &amp;, SharedPtr&lt; StreamMetadata &gt; &amp;, bool transfer=true)</td></tr> <tr class="memdesc:ace6154e2dd4418cc456e5f17a8c46f1d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Associate the given stream with (a shared pointer to) an object that stores metadata (file format, compression scheme, etc.) for use when reading from or writing to the stream. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#ace6154e2dd4418cc456e5f17a8c46f1d">More...</a><br /></td></tr> <tr class="separator:ace6154e2dd4418cc456e5f17a8c46f1d"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a6d1dfc9ea7185ab3a857455029de3c05"><td class="memItemLeft" align="right" valign="top"><a class="el" href="Platform_8h.html#a78ead02913edfee18be9d5982b788611">OPENVDB_API</a> SharedPtr&lt; StreamMetadata &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceopenvdb_1_1v8__0_1_1io.html#a6d1dfc9ea7185ab3a857455029de3c05">clearStreamMetadataPtr</a> (std::ios_base &amp;)</td></tr> <tr class="memdesc:a6d1dfc9ea7185ab3a857455029de3c05"><td class="mdescLeft">&#160;</td><td class="mdescRight">Dissociate the given stream from its metadata object (if it has one) and return a shared pointer to the object. <a href="namespaceopenvdb_1_1v8__0_1_1io.html#a6d1dfc9ea7185ab3a857455029de3c05">More...</a><br /></td></tr> <tr class="separator:a6d1dfc9ea7185ab3a857455029de3c05"><td class="memSeparator" colspan="2">&#160;</td></tr> </table> </div><!-- contents --> <!-- start footer part --> <hr class="footer"/><address class="footer"><small> Generated by &#160;<a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/> </a> 1.8.11 </small></address> </body> </html>
132.130841
458
0.75053
46ac3bb18d264737cfa6a5e85276e655e5a40b4a
37,201
html
HTML
docs/generated/docs/classsensesp_1_1_s_k_put_request_base.html
gregsyoung/SensESP
4be5286f9b156b94ce6f7918cdfadbe40580b08c
[ "Apache-2.0" ]
null
null
null
docs/generated/docs/classsensesp_1_1_s_k_put_request_base.html
gregsyoung/SensESP
4be5286f9b156b94ce6f7918cdfadbe40580b08c
[ "Apache-2.0" ]
null
null
null
docs/generated/docs/classsensesp_1_1_s_k_put_request_base.html
gregsyoung/SensESP
4be5286f9b156b94ce6f7918cdfadbe40580b08c
[ "Apache-2.0" ]
null
null
null
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <meta http-equiv="X-UA-Compatible" content="IE=11"/> <meta name="generator" content="Doxygen 1.9.2"/> <meta name="viewport" content="width=device-width, initial-scale=1"/> <title>SensESP: sensesp::SKPutRequestBase Class Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="jquery.js"></script> <script type="text/javascript" src="dynsections.js"></script> <link href="navtree.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="resize.js"></script> <script type="text/javascript" src="navtreedata.js"></script> <script type="text/javascript" src="navtree.js"></script> <link href="search/search.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="search/searchdata.js"></script> <script type="text/javascript" src="search/search.js"></script> <script type="text/x-mathjax-config"> MathJax.Hub.Config({ extensions: ["tex2jax.js"], jax: ["input/TeX","output/HTML-CSS"], }); </script> <script type="text/javascript" async="async" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/MathJax.js"></script> <link href="doxygen.css" rel="stylesheet" type="text/css" /> </head> <body> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td id="projectalign" style="padding-left: 0.5em;"> <div id="projectname">SensESP<span id="projectnumber">&#160;2.2.1</span> </div> <div id="projectbrief">Universal Signal K sensor toolkit ESP32</div> </td> </tr> </tbody> </table> </div> <!-- end header part --> <!-- Generated by Doxygen 1.9.2 --> <script type="text/javascript"> /* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */ var searchBox = new SearchBox("searchBox", "search",'Search','.html'); /* @license-end */ </script> <script type="text/javascript" src="menudata.js"></script> <script type="text/javascript" src="menu.js"></script> <script type="text/javascript"> /* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */ $(function() { initMenu('',true,false,'search.php','Search'); $(document).ready(function() { init_search(); }); }); /* @license-end */ </script> <div id="main-nav"></div> </div><!-- top --> <div id="side-nav" class="ui-resizable side-nav-resizable"> <div id="nav-tree"> <div id="nav-tree-contents"> <div id="nav-sync" class="sync"></div> </div> </div> <div id="splitbar" style="-moz-user-select:none;" class="ui-resizable-handle"> </div> </div> <script type="text/javascript"> /* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */ $(document).ready(function(){initNavTree('classsensesp_1_1_s_k_put_request_base.html',''); initResizable(); }); /* @license-end */ </script> <div id="doc-content"> <!-- window showing the filter options --> <div id="MSearchSelectWindow" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" onkeydown="return searchBox.OnSearchSelectKey(event)"> </div> <!-- iframe showing the search results (closed by default) --> <div id="MSearchResultsWindow"> <iframe src="javascript:void(0)" frameborder="0" name="MSearchResults" id="MSearchResults"> </iframe> </div> <div class="header"> <div class="summary"> <a href="#pub-methods">Public Member Functions</a> &#124; <a href="#pro-methods">Protected Member Functions</a> &#124; <a href="#pro-attribs">Protected Attributes</a> &#124; <a href="classsensesp_1_1_s_k_put_request_base-members.html">List of all members</a> </div> <div class="headertitle"><div class="title">sensesp::SKPutRequestBase Class Reference<span class="mlabels"><span class="mlabel">abstract</span></span></div></div> </div><!--header--> <div class="contents"> <p>A base class for all template variations of the PUT request class <a class="el" href="classsensesp_1_1_s_k_put_request.html" title="Used to send requests to the server to change the value of the specified path to a specific value acc...">SKPutRequest</a>. This base class keeps the compiler from generating reduntant object code for common functionality of each template version. <a href="classsensesp_1_1_s_k_put_request_base.html#details">More...</a></p> <p><code>#include &lt;<a class="el" href="signalk__put__request_8h_source.html">sensesp/signalk/signalk_put_request.h</a>&gt;</code></p> <div class="dynheader"> Inheritance diagram for sensesp::SKPutRequestBase:</div> <div class="dyncontent"> <div class="center"><iframe scrolling="no" frameborder="0" src="classsensesp_1_1_s_k_put_request_base__inherit__graph.svg" width="334" height="187"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe> </div> <center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div> <table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-methods" name="pub-methods"></a> Public Member Functions</h2></td></tr> <tr class="memitem:a48320506cc048f75493f02200c2a8f4f"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a48320506cc048f75493f02200c2a8f4f">SKPutRequestBase</a> (String <a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a96a0e71f7bd32a449576af8a1df8e38e">sk_path</a>, String config_path=&quot;&quot;, uint32_t <a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a58a8fece5cbf95e7b09eedbdf4a9d33c">timeout</a>=5000)</td></tr> <tr class="separator:a48320506cc048f75493f02200c2a8f4f"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a7be4f289fb9aa1c06a7ae49510751665"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a7be4f289fb9aa1c06a7ae49510751665">get_configuration</a> (JsonObject &amp;doc) override</td></tr> <tr class="separator:a7be4f289fb9aa1c06a7ae49510751665"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a37e6f3d77ca1006d43df73ba9722d628"><td class="memItemLeft" align="right" valign="top">virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a37e6f3d77ca1006d43df73ba9722d628">set_configuration</a> (const JsonObject &amp;config) override</td></tr> <tr class="separator:a37e6f3d77ca1006d43df73ba9722d628"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a4f3018e06dee0f3e3b98e8681fff5e9e"><td class="memItemLeft" align="right" valign="top">virtual String&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a4f3018e06dee0f3e3b98e8681fff5e9e">get_config_schema</a> () override</td></tr> <tr class="separator:a4f3018e06dee0f3e3b98e8681fff5e9e"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a73249d0021992f9224fd0c6da11d1566"><td class="memItemLeft" align="right" valign="top">String&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a73249d0021992f9224fd0c6da11d1566">get_sk_path</a> ()</td></tr> <tr class="separator:a73249d0021992f9224fd0c6da11d1566"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a869f1d2df93c2490605bf0f81c1b933d"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a869f1d2df93c2490605bf0f81c1b933d">request_pending</a> ()</td></tr> <tr class="separator:a869f1d2df93c2490605bf0f81c1b933d"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="inherit_header pub_methods_classsensesp_1_1_configurable"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_classsensesp_1_1_configurable')"><img src="closed.png" alt="-"/>&#160;Public Member Functions inherited from <a class="el" href="classsensesp_1_1_configurable.html">sensesp::Configurable</a></td></tr> <tr class="memitem:ae24b0359ade0718a19659af65e94d05b inherit pub_methods_classsensesp_1_1_configurable"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_configurable.html#ae24b0359ade0718a19659af65e94d05b">Configurable</a> (String config_path)</td></tr> <tr class="separator:ae24b0359ade0718a19659af65e94d05b inherit pub_methods_classsensesp_1_1_configurable"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a4202ce8a5b9ad23d2a2be27de11153f4 inherit pub_methods_classsensesp_1_1_configurable"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_configurable.html#a4202ce8a5b9ad23d2a2be27de11153f4">save_configuration</a> ()</td></tr> <tr class="separator:a4202ce8a5b9ad23d2a2be27de11153f4 inherit pub_methods_classsensesp_1_1_configurable"><td class="memSeparator" colspan="2">&#160;</td></tr> </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pro-methods" name="pro-methods"></a> Protected Member Functions</h2></td></tr> <tr class="memitem:a8a60c171c008e367a92d93f62e291dae"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a8a60c171c008e367a92d93f62e291dae">send_put_request</a> ()</td></tr> <tr class="separator:a8a60c171c008e367a92d93f62e291dae"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a29be849c72b164333a32109a0568a0dd"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a29be849c72b164333a32109a0568a0dd">set_put_value</a> (JsonObject &amp;put_data)=0</td></tr> <tr class="separator:a29be849c72b164333a32109a0568a0dd"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:aba1496917cfc83887cc5032bb6bf4548"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html#aba1496917cfc83887cc5032bb6bf4548">on_response</a> (DynamicJsonDocument &amp;response)</td></tr> <tr class="separator:aba1496917cfc83887cc5032bb6bf4548"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="inherit_header pro_methods_classsensesp_1_1_configurable"><td colspan="2" onclick="javascript:toggleInherit('pro_methods_classsensesp_1_1_configurable')"><img src="closed.png" alt="-"/>&#160;Protected Member Functions inherited from <a class="el" href="classsensesp_1_1_configurable.html">sensesp::Configurable</a></td></tr> <tr class="memitem:ac97542fd5a24ae306adb77f3d1ba563a inherit pro_methods_classsensesp_1_1_configurable"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_configurable.html#ac97542fd5a24ae306adb77f3d1ba563a">load_configuration</a> ()</td></tr> <tr class="separator:ac97542fd5a24ae306adb77f3d1ba563a inherit pro_methods_classsensesp_1_1_configurable"><td class="memSeparator" colspan="2">&#160;</td></tr> </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pro-attribs" name="pro-attribs"></a> Protected Attributes</h2></td></tr> <tr class="memitem:a96a0e71f7bd32a449576af8a1df8e38e"><td class="memItemLeft" align="right" valign="top">String&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a96a0e71f7bd32a449576af8a1df8e38e">sk_path</a></td></tr> <tr class="separator:a96a0e71f7bd32a449576af8a1df8e38e"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a58a8fece5cbf95e7b09eedbdf4a9d33c"><td class="memItemLeft" align="right" valign="top">uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a58a8fece5cbf95e7b09eedbdf4a9d33c">timeout</a></td></tr> <tr class="separator:a58a8fece5cbf95e7b09eedbdf4a9d33c"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a70499767ebda2e8b9b536c88192649f6"><td class="memItemLeft" align="right" valign="top">String&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a70499767ebda2e8b9b536c88192649f6">pending_request_id_</a></td></tr> <tr class="separator:a70499767ebda2e8b9b536c88192649f6"><td class="memSeparator" colspan="2">&#160;</td></tr> </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="inherited" name="inherited"></a> Additional Inherited Members</h2></td></tr> <tr class="inherit_header pub_static_methods_classsensesp_1_1_s_k_request"><td colspan="2" onclick="javascript:toggleInherit('pub_static_methods_classsensesp_1_1_s_k_request')"><img src="closed.png" alt="-"/>&#160;Static Public Member Functions inherited from <a class="el" href="classsensesp_1_1_s_k_request.html">sensesp::SKRequest</a></td></tr> <tr class="memitem:a61d615a0f319f6f7a38d968af4620eb2 inherit pub_static_methods_classsensesp_1_1_s_k_request"><td class="memItemLeft" align="right" valign="top">static String&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_request.html#a61d615a0f319f6f7a38d968af4620eb2">send_request</a> (DynamicJsonDocument &amp;request, std::function&lt; void(DynamicJsonDocument &amp;)&gt; callback, uint32_t timeout=5000)</td></tr> <tr class="separator:a61d615a0f319f6f7a38d968af4620eb2 inherit pub_static_methods_classsensesp_1_1_s_k_request"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a1aab6e4dfa67a303b3d8048f38f9f9cc inherit pub_static_methods_classsensesp_1_1_s_k_request"><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_request.html#a1aab6e4dfa67a303b3d8048f38f9f9cc">handle_response</a> (DynamicJsonDocument &amp;response)</td></tr> <tr class="separator:a1aab6e4dfa67a303b3d8048f38f9f9cc inherit pub_static_methods_classsensesp_1_1_s_k_request"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="inherit_header pub_attribs_classsensesp_1_1_configurable"><td colspan="2" onclick="javascript:toggleInherit('pub_attribs_classsensesp_1_1_configurable')"><img src="closed.png" alt="-"/>&#160;Public Attributes inherited from <a class="el" href="classsensesp_1_1_configurable.html">sensesp::Configurable</a></td></tr> <tr class="memitem:aded48ebfe23c7bee1845c7ab99c63a6e inherit pub_attribs_classsensesp_1_1_configurable"><td class="memItemLeft" align="right" valign="top">const String&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_configurable.html#aded48ebfe23c7bee1845c7ab99c63a6e">config_path_</a></td></tr> <tr class="separator:aded48ebfe23c7bee1845c7ab99c63a6e inherit pub_attribs_classsensesp_1_1_configurable"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="inherit_header pro_static_methods_classsensesp_1_1_s_k_request"><td colspan="2" onclick="javascript:toggleInherit('pro_static_methods_classsensesp_1_1_s_k_request')"><img src="closed.png" alt="-"/>&#160;Static Protected Member Functions inherited from <a class="el" href="classsensesp_1_1_s_k_request.html">sensesp::SKRequest</a></td></tr> <tr class="memitem:af3556571b45b5ce5ab74831cb5605ded inherit pro_static_methods_classsensesp_1_1_s_k_request"><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_request.html#af3556571b45b5ce5ab74831cb5605ded">remove_request</a> (String request_id)</td></tr> <tr class="separator:af3556571b45b5ce5ab74831cb5605ded inherit pro_static_methods_classsensesp_1_1_s_k_request"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:a9af8d69fb226c27304ceff7646bc86ca inherit pro_static_methods_classsensesp_1_1_s_k_request"><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classsensesp_1_1_s_k_request_1_1_pending_request.html">PendingRequest</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_request.html#a9af8d69fb226c27304ceff7646bc86ca">get_request</a> (String request_id)</td></tr> <tr class="separator:a9af8d69fb226c27304ceff7646bc86ca inherit pro_static_methods_classsensesp_1_1_s_k_request"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="inherit_header pro_static_attribs_classsensesp_1_1_s_k_request"><td colspan="2" onclick="javascript:toggleInherit('pro_static_attribs_classsensesp_1_1_s_k_request')"><img src="closed.png" alt="-"/>&#160;Static Protected Attributes inherited from <a class="el" href="classsensesp_1_1_s_k_request.html">sensesp::SKRequest</a></td></tr> <tr class="memitem:a1b9232410aa8733fce6d408761af0f12 inherit pro_static_attribs_classsensesp_1_1_s_k_request"><td class="memItemLeft" align="right" valign="top">static std::map&lt; String, <a class="el" href="classsensesp_1_1_s_k_request_1_1_pending_request.html">PendingRequest</a> * &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsensesp_1_1_s_k_request.html#a1b9232410aa8733fce6d408761af0f12">request_map</a></td></tr> <tr class="separator:a1b9232410aa8733fce6d408761af0f12 inherit pro_static_attribs_classsensesp_1_1_s_k_request"><td class="memSeparator" colspan="2">&#160;</td></tr> </table> <a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2> <div class="textblock"><p >A base class for all template variations of the PUT request class <a class="el" href="classsensesp_1_1_s_k_put_request.html" title="Used to send requests to the server to change the value of the specified path to a specific value acc...">SKPutRequest</a>. This base class keeps the compiler from generating reduntant object code for common functionality of each template version. </p> <dl class="section see"><dt>See also</dt><dd><a class="el" href="classsensesp_1_1_s_k_put_request.html" title="Used to send requests to the server to change the value of the specified path to a specific value acc...">SKPutRequest</a> See <a href="https://signalk.org/specification/1.5.0/doc/put.html">https://signalk.org/specification/1.5.0/doc/put.html</a> </dd></dl> <p class="definition">Definition at line <a class="el" href="signalk__put__request_8h_source.html#l00075">75</a> of file <a class="el" href="signalk__put__request_8h_source.html">signalk_put_request.h</a>.</p> </div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2> <a id="a48320506cc048f75493f02200c2a8f4f" name="a48320506cc048f75493f02200c2a8f4f"></a> <h2 class="memtitle"><span class="permalink"><a href="#a48320506cc048f75493f02200c2a8f4f">&#9670;&nbsp;</a></span>SKPutRequestBase()</h2> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">sensesp::SKPutRequestBase::SKPutRequestBase </td> <td>(</td> <td class="paramtype">String&#160;</td> <td class="paramname"><em>sk_path</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">String&#160;</td> <td class="paramname"><em>config_path</em> = <code>&quot;&quot;</code>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">uint32_t&#160;</td> <td class="paramname"><em>timeout</em> = <code>5000</code>&#160;</td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div><div class="memdoc"> <p >The constructor </p><dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">sk_path</td><td>The SignalK path the put request will be made on </td></tr> <tr><td class="paramname">config_path</td><td>The configuration path to save the configuration </td></tr> <tr><td class="paramname">timeout</td><td>The number of milliseconds to wait for a COMPLETED or FAILED response to be received from the server </td></tr> </table> </dd> </dl> <p class="definition">Definition at line <a class="el" href="signalk__put__request_8cpp_source.html#l00094">94</a> of file <a class="el" href="signalk__put__request_8cpp_source.html">signalk_put_request.cpp</a>.</p> <div class="dynheader"> Here is the call graph for this function:</div> <div class="dyncontent"> <div class="center"><div class="zoom"><iframe scrolling="no" frameborder="0" src="classsensesp_1_1_s_k_put_request_base_a48320506cc048f75493f02200c2a8f4f_cgraph.svg" width="100%" height="378"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe></div> </div> </div> </div> </div> <h2 class="groupheader">Member Function Documentation</h2> <a id="a4f3018e06dee0f3e3b98e8681fff5e9e" name="a4f3018e06dee0f3e3b98e8681fff5e9e"></a> <h2 class="memtitle"><span class="permalink"><a href="#a4f3018e06dee0f3e3b98e8681fff5e9e">&#9670;&nbsp;</a></span>get_config_schema()</h2> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">String sensesp::SKPutRequestBase::get_config_schema </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">override</span><span class="mlabel">virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p >Returns a configuration schema that specifies the key/value pairs that can be expected when calling <a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a7be4f289fb9aa1c06a7ae49510751665">get_configuration()</a>, or are expected by <a class="el" href="classsensesp_1_1_s_k_put_request_base.html#a37e6f3d77ca1006d43df73ba9722d628">set_configuration()</a>. The schema will be in JSON Schema format </p><dl class="section see"><dt>See also</dt><dd><a href="https://json-schema.org">https://json-schema.org</a> </dd></dl> <p>Reimplemented from <a class="el" href="classsensesp_1_1_configurable.html#a2a0b1727f0e7fca0730381e030360a1a">sensesp::Configurable</a>.</p> <p class="definition">Definition at line <a class="el" href="signalk__put__request_8cpp_source.html#l00134">134</a> of file <a class="el" href="signalk__put__request_8cpp_source.html">signalk_put_request.cpp</a>.</p> </div> </div> <a id="a7be4f289fb9aa1c06a7ae49510751665" name="a7be4f289fb9aa1c06a7ae49510751665"></a> <h2 class="memtitle"><span class="permalink"><a href="#a7be4f289fb9aa1c06a7ae49510751665">&#9670;&nbsp;</a></span>get_configuration()</h2> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">void sensesp::SKPutRequestBase::get_configuration </td> <td>(</td> <td class="paramtype">JsonObject &amp;&#160;</td> <td class="paramname"><em>configObject</em></td><td>)</td> <td></td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">override</span><span class="mlabel">virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p >Returns the current configuration data as a JsonObject. In general, the current state of local member variables are saved to a new object created with JsonDocument::as&lt;JsonObject&gt;() and returned. </p> <p>Reimplemented from <a class="el" href="classsensesp_1_1_configurable.html#a7785e86a2e662ff0291f7a6fb043ea91">sensesp::Configurable</a>.</p> <p class="definition">Definition at line <a class="el" href="signalk__put__request_8cpp_source.html#l00123">123</a> of file <a class="el" href="signalk__put__request_8cpp_source.html">signalk_put_request.cpp</a>.</p> </div> </div> <a id="a73249d0021992f9224fd0c6da11d1566" name="a73249d0021992f9224fd0c6da11d1566"></a> <h2 class="memtitle"><span class="permalink"><a href="#a73249d0021992f9224fd0c6da11d1566">&#9670;&nbsp;</a></span>get_sk_path()</h2> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">String sensesp::SKPutRequestBase::get_sk_path </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">inline</span></span> </td> </tr> </table> </div><div class="memdoc"> <p >Returns the Signal K path this object makes requests to </p> <p class="definition">Definition at line <a class="el" href="signalk__put__request_8h_source.html#l00095">95</a> of file <a class="el" href="signalk__put__request_8h_source.html">signalk_put_request.h</a>.</p> </div> </div> <a id="aba1496917cfc83887cc5032bb6bf4548" name="aba1496917cfc83887cc5032bb6bf4548"></a> <h2 class="memtitle"><span class="permalink"><a href="#aba1496917cfc83887cc5032bb6bf4548">&#9670;&nbsp;</a></span>on_response()</h2> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">void sensesp::SKPutRequestBase::on_response </td> <td>(</td> <td class="paramtype">DynamicJsonDocument &amp;&#160;</td> <td class="paramname"><em>response</em></td><td>)</td> <td></td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">protected</span><span class="mlabel">virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p >Called whenever a response to a request has been received from the server </p> <p class="definition">Definition at line <a class="el" href="signalk__put__request_8cpp_source.html#l00116">116</a> of file <a class="el" href="signalk__put__request_8cpp_source.html">signalk_put_request.cpp</a>.</p> <div class="dynheader"> Here is the caller graph for this function:</div> <div class="dyncontent"> <div class="center"><iframe scrolling="no" frameborder="0" src="classsensesp_1_1_s_k_put_request_base_aba1496917cfc83887cc5032bb6bf4548_icgraph.svg" width="666" height="52"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe> </div> </div> </div> </div> <a id="a869f1d2df93c2490605bf0f81c1b933d" name="a869f1d2df93c2490605bf0f81c1b933d"></a> <h2 class="memtitle"><span class="permalink"><a href="#a869f1d2df93c2490605bf0f81c1b933d">&#9670;&nbsp;</a></span>request_pending()</h2> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">bool sensesp::SKPutRequestBase::request_pending </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p >Returns TRUE if there is currently a PUT request pending (i.e. this class has send a request, and it has not yet received a reply or timeout) </p> <p class="definition">Definition at line <a class="el" href="signalk__put__request_8cpp_source.html#l00112">112</a> of file <a class="el" href="signalk__put__request_8cpp_source.html">signalk_put_request.cpp</a>.</p> <div class="dynheader"> Here is the call graph for this function:</div> <div class="dyncontent"> <div class="center"><iframe scrolling="no" frameborder="0" src="classsensesp_1_1_s_k_put_request_base_a869f1d2df93c2490605bf0f81c1b933d_cgraph.svg" width="402" height="52"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe> </div> </div> <div class="dynheader"> Here is the caller graph for this function:</div> <div class="dyncontent"> <div class="center"><iframe scrolling="no" frameborder="0" src="classsensesp_1_1_s_k_put_request_base_a869f1d2df93c2490605bf0f81c1b933d_icgraph.svg" width="422" height="52"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe> </div> </div> </div> </div> <a id="a8a60c171c008e367a92d93f62e291dae" name="a8a60c171c008e367a92d93f62e291dae"></a> <h2 class="memtitle"><span class="permalink"><a href="#a8a60c171c008e367a92d93f62e291dae">&#9670;&nbsp;</a></span>send_put_request()</h2> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">void sensesp::SKPutRequestBase::send_put_request </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">protected</span></span> </td> </tr> </table> </div><div class="memdoc"> <p >Sends the put request to the server </p> <p class="definition">Definition at line <a class="el" href="signalk__put__request_8cpp_source.html#l00100">100</a> of file <a class="el" href="signalk__put__request_8cpp_source.html">signalk_put_request.cpp</a>.</p> <div class="dynheader"> Here is the call graph for this function:</div> <div class="dyncontent"> <div class="center"><div class="zoom"><iframe scrolling="no" frameborder="0" src="classsensesp_1_1_s_k_put_request_base_a8a60c171c008e367a92d93f62e291dae_cgraph.svg" width="100%" height="514"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe></div> </div> </div> <div class="dynheader"> Here is the caller graph for this function:</div> <div class="dyncontent"> <div class="center"><iframe scrolling="no" frameborder="0" src="classsensesp_1_1_s_k_put_request_base_a8a60c171c008e367a92d93f62e291dae_icgraph.svg" width="422" height="52"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe> </div> </div> </div> </div> <a id="a37e6f3d77ca1006d43df73ba9722d628" name="a37e6f3d77ca1006d43df73ba9722d628"></a> <h2 class="memtitle"><span class="permalink"><a href="#a37e6f3d77ca1006d43df73ba9722d628">&#9670;&nbsp;</a></span>set_configuration()</h2> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">bool sensesp::SKPutRequestBase::set_configuration </td> <td>(</td> <td class="paramtype">const JsonObject &amp;&#160;</td> <td class="paramname"><em>config</em></td><td>)</td> <td></td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">override</span><span class="mlabel">virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p >Sets the current state of local member variables using the data stored in config. </p> <p>Reimplemented from <a class="el" href="classsensesp_1_1_configurable.html#a0deaa5b717cd0f60d0105835cd6b595a">sensesp::Configurable</a>.</p> <p class="definition">Definition at line <a class="el" href="signalk__put__request_8cpp_source.html#l00136">136</a> of file <a class="el" href="signalk__put__request_8cpp_source.html">signalk_put_request.cpp</a>.</p> </div> </div> <a id="a29be849c72b164333a32109a0568a0dd" name="a29be849c72b164333a32109a0568a0dd"></a> <h2 class="memtitle"><span class="permalink"><a href="#a29be849c72b164333a32109a0568a0dd">&#9670;&nbsp;</a></span>set_put_value()</h2> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">virtual void sensesp::SKPutRequestBase::set_put_value </td> <td>(</td> <td class="paramtype">JsonObject &amp;&#160;</td> <td class="paramname"><em>put_data</em></td><td>)</td> <td></td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">protected</span><span class="mlabel">pure virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p >Sets the "value" field of the put request with the appropriate value. </p> <p>Implemented in <a class="el" href="classsensesp_1_1_s_k_put_request.html#a9d59c592c83a8d4a95020785df211b3d">sensesp::SKPutRequest&lt; T &gt;</a>.</p> <div class="dynheader"> Here is the caller graph for this function:</div> <div class="dyncontent"> <div class="center"><iframe scrolling="no" frameborder="0" src="classsensesp_1_1_s_k_put_request_base_a29be849c72b164333a32109a0568a0dd_icgraph.svg" width="666" height="52"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe> </div> </div> </div> </div> <h2 class="groupheader">Member Data Documentation</h2> <a id="a70499767ebda2e8b9b536c88192649f6" name="a70499767ebda2e8b9b536c88192649f6"></a> <h2 class="memtitle"><span class="permalink"><a href="#a70499767ebda2e8b9b536c88192649f6">&#9670;&nbsp;</a></span>pending_request_id_</h2> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">String sensesp::SKPutRequestBase::pending_request_id_</td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">protected</span></span> </td> </tr> </table> </div><div class="memdoc"> <p class="definition">Definition at line <a class="el" href="signalk__put__request_8h_source.html#l00124">124</a> of file <a class="el" href="signalk__put__request_8h_source.html">signalk_put_request.h</a>.</p> </div> </div> <a id="a96a0e71f7bd32a449576af8a1df8e38e" name="a96a0e71f7bd32a449576af8a1df8e38e"></a> <h2 class="memtitle"><span class="permalink"><a href="#a96a0e71f7bd32a449576af8a1df8e38e">&#9670;&nbsp;</a></span>sk_path</h2> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">String sensesp::SKPutRequestBase::sk_path</td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">protected</span></span> </td> </tr> </table> </div><div class="memdoc"> <p class="definition">Definition at line <a class="el" href="signalk__put__request_8h_source.html#l00122">122</a> of file <a class="el" href="signalk__put__request_8h_source.html">signalk_put_request.h</a>.</p> </div> </div> <a id="a58a8fece5cbf95e7b09eedbdf4a9d33c" name="a58a8fece5cbf95e7b09eedbdf4a9d33c"></a> <h2 class="memtitle"><span class="permalink"><a href="#a58a8fece5cbf95e7b09eedbdf4a9d33c">&#9670;&nbsp;</a></span>timeout</h2> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">uint32_t sensesp::SKPutRequestBase::timeout</td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">protected</span></span> </td> </tr> </table> </div><div class="memdoc"> <p class="definition">Definition at line <a class="el" href="signalk__put__request_8h_source.html#l00123">123</a> of file <a class="el" href="signalk__put__request_8h_source.html">signalk_put_request.h</a>.</p> </div> </div> <hr/>The documentation for this class was generated from the following files:<ul> <li>src/sensesp/signalk/<a class="el" href="signalk__put__request_8h_source.html">signalk_put_request.h</a></li> <li>src/sensesp/signalk/<a class="el" href="signalk__put__request_8cpp_source.html">signalk_put_request.cpp</a></li> </ul> </div><!-- contents --> </div><!-- doc-content --> <!-- start footer part --> <div id="nav-path" class="navpath"><!-- id is needed for treeview function! --> <ul> <li class="navelem"><a class="el" href="namespacesensesp.html">sensesp</a></li><li class="navelem"><a class="el" href="classsensesp_1_1_s_k_put_request_base.html">SKPutRequestBase</a></li> <li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.2 </li> </ul> </div> </body> </html>
64.139655
562
0.727803
9d2513b88d04dd309cd092d6859547682376a74b
6,308
dart
Dart
lib/presentation/catalog/components/catalog_loan_card.dart
MuringeMuthoni/flutter_kakao_bank_ui_clone
9ce98c1a8640fec322410be57f073eb744bf8815
[ "MIT" ]
9
2020-10-28T13:32:40.000Z
2022-03-11T10:00:39.000Z
lib/presentation/catalog/components/catalog_loan_card.dart
MuringeMuthoni/flutter_kakao_bank_ui_clone
9ce98c1a8640fec322410be57f073eb744bf8815
[ "MIT" ]
null
null
null
lib/presentation/catalog/components/catalog_loan_card.dart
MuringeMuthoni/flutter_kakao_bank_ui_clone
9ce98c1a8640fec322410be57f073eb744bf8815
[ "MIT" ]
8
2021-05-16T12:01:19.000Z
2022-03-30T13:12:57.000Z
import 'package:flutter/material.dart'; class CatalogLoanCard extends StatelessWidget { const CatalogLoanCard({Key key}) : super(key: key); @override Widget build(BuildContext context) { return Padding( padding: const EdgeInsets.symmetric(horizontal: 10, vertical: 20), child: Column( children: [ Container( height: 50, child: Row( children: [ Text( 'Loan', style: TextStyle( fontWeight: FontWeight.bold, color: Colors.black, fontSize: 18, ), ), ], ), ), SizedBox(height: 20,), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ Expanded( child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ Text( "Emergency Loan", style: TextStyle( fontWeight: FontWeight.bold, ), ), SizedBox(height: 5,), Text( "Useful when you need cash", style: TextStyle( color: Colors.black.withOpacity(0.6), fontWeight: FontWeight.w500, ), ) ], ), ), Text( "APY 3.20%", style: TextStyle( color: Colors.blueAccent, fontWeight: FontWeight.bold, ), ) ], ), Divider(height: 30,), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ Expanded( child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ Text( "Emergency Loan", style: TextStyle( fontWeight: FontWeight.bold, ), ), SizedBox(height: 5,), Text( "Useful when you need cash", style: TextStyle( color: Colors.black.withOpacity(0.6), fontWeight: FontWeight.w500, ), ) ], ), ), Text( "APY 3.20%", style: TextStyle( color: Colors.blueAccent, fontWeight: FontWeight.bold, ), ) ], ), Divider(height: 30,), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ Expanded( child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ Text( "Emergency Loan", style: TextStyle( fontWeight: FontWeight.bold, ), ), SizedBox(height: 5,), Text( "Useful when you need cash", style: TextStyle( color: Colors.black.withOpacity(0.6), fontWeight: FontWeight.w500, ), ) ], ), ), Text( "APY 3.20%", style: TextStyle( color: Colors.blueAccent, fontWeight: FontWeight.bold, ), ) ], ), Divider(height: 30,), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ Expanded( child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ Text( "Emergency Loan", style: TextStyle( fontWeight: FontWeight.bold, ), ), SizedBox(height: 5,), Text( "Useful when you need cash", style: TextStyle( color: Colors.black.withOpacity(0.6), fontWeight: FontWeight.w500, ), ) ], ), ), Text( "APY 3.20%", style: TextStyle( color: Colors.blueAccent, fontWeight: FontWeight.bold, ), ) ], ), Divider(height: 30,), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ Expanded( child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ Text( "Emergency Loan", style: TextStyle( fontWeight: FontWeight.bold, ), ), SizedBox(height: 5,), Text( "Useful when you need cash", style: TextStyle( color: Colors.black.withOpacity(0.6), fontWeight: FontWeight.w500, ), ) ], ), ), Text( "APY 3.20%", style: TextStyle( color: Colors.blueAccent, fontWeight: FontWeight.bold, ), ) ], ), Divider(height: 30,), ], ), ); } }
31.073892
72
0.350349
5b256a25c9f00713f227ccbe963603e3f5d188c1
304
dart
Dart
stream_feed_dart/lib/src/core/lookup_attribute.dart
aryalg/stream_feed_dart
69e8293c93519fb17400e59a5ba1dcfed099e7a4
[ "MIT" ]
null
null
null
stream_feed_dart/lib/src/core/lookup_attribute.dart
aryalg/stream_feed_dart
69e8293c93519fb17400e59a5ba1dcfed099e7a4
[ "MIT" ]
null
null
null
stream_feed_dart/lib/src/core/lookup_attribute.dart
aryalg/stream_feed_dart
69e8293c93519fb17400e59a5ba1dcfed099e7a4
[ "MIT" ]
null
null
null
enum LookupAttribute { activity_id, reaction_id, user_id, } extension LookupAttributeX on LookupAttribute { String? get attr => { LookupAttribute.activity_id: 'activity_id', LookupAttribute.reaction_id: 'reaction_id', LookupAttribute.user_id: 'user_id', }[this]; }
21.714286
51
0.690789
11f4aa94bc95a1aafd0de82b873e628aee5119c2
364
html
HTML
app/templates/sidebar.html
koneb71/epixdeploy
910e34c7d86df3680885cfcf4647534d5eb72d95
[ "MIT" ]
null
null
null
app/templates/sidebar.html
koneb71/epixdeploy
910e34c7d86df3680885cfcf4647534d5eb72d95
[ "MIT" ]
null
null
null
app/templates/sidebar.html
koneb71/epixdeploy
910e34c7d86df3680885cfcf4647534d5eb72d95
[ "MIT" ]
null
null
null
<!-- Nav Item - Charts --> <li class="nav-item"> <a class="nav-link" href="{% url 'users' %}"> <i class="fas fa-fw fa-chart-area"></i> <span>Users</span></a> </li> <!-- Nav Item - Tables --> <li class="nav-item"> <a class="nav-link" href="tables.html"> <i class="fas fa-fw fa-table"></i> <span>Tables</span></a> </li>
24.266667
49
0.508242
2e24ea6d6aca346d633c5e83de6ca589a45096f3
1,154
sql
SQL
tests/queries/0_stateless/00862_decimal_in.sql
pdv-ru/ClickHouse
0ff975bcf3008fa6c6373cbdfed16328e3863ec5
[ "Apache-2.0" ]
15,577
2019-09-23T11:57:53.000Z
2022-03-31T18:21:48.000Z
tests/queries/0_stateless/00862_decimal_in.sql
pdv-ru/ClickHouse
0ff975bcf3008fa6c6373cbdfed16328e3863ec5
[ "Apache-2.0" ]
16,476
2019-09-23T11:47:00.000Z
2022-03-31T23:06:01.000Z
tests/queries/0_stateless/00862_decimal_in.sql
pdv-ru/ClickHouse
0ff975bcf3008fa6c6373cbdfed16328e3863ec5
[ "Apache-2.0" ]
3,633
2019-09-23T12:18:28.000Z
2022-03-31T15:55:48.000Z
DROP TABLE IF EXISTS temp; CREATE TABLE temp ( x Decimal(38,2), y Nullable(Decimal(38,2)) ) ENGINE = Memory; INSERT INTO temp VALUES (32, 32), (64, 64), (128, 128); SELECT * FROM temp WHERE x IN (toDecimal128(128, 2)); SELECT * FROM temp WHERE y IN (toDecimal128(128, 2)); SELECT * FROM temp WHERE x IN (toDecimal128(128, 1)); SELECT * FROM temp WHERE x IN (toDecimal128(128, 3)); SELECT * FROM temp WHERE y IN (toDecimal128(128, 1)); SELECT * FROM temp WHERE y IN (toDecimal128(128, 3)); SELECT * FROM temp WHERE x IN (toDecimal32(32, 1)); SELECT * FROM temp WHERE x IN (toDecimal32(32, 2)); SELECT * FROM temp WHERE x IN (toDecimal32(32, 3)); SELECT * FROM temp WHERE y IN (toDecimal32(32, 1)); SELECT * FROM temp WHERE y IN (toDecimal32(32, 2)); SELECT * FROM temp WHERE y IN (toDecimal32(32, 3)); SELECT * FROM temp WHERE x IN (toDecimal64(64, 1)); SELECT * FROM temp WHERE x IN (toDecimal64(64, 2)); SELECT * FROM temp WHERE x IN (toDecimal64(64, 3)); SELECT * FROM temp WHERE y IN (toDecimal64(64, 1)); SELECT * FROM temp WHERE y IN (toDecimal64(64, 2)); SELECT * FROM temp WHERE y IN (toDecimal64(64, 3)); DROP TABLE IF EXISTS temp;
34.969697
55
0.687175
9be820dc54f871f66603582a206ef5f95d341835
1,435
sql
SQL
resources/sql/postgres/getTableMeta.sql
sitch/schemats
48dcb378f3beacf8a7b5e528bc22832e8a25b43a
[ "MIT" ]
1
2022-02-21T03:52:56.000Z
2022-02-21T03:52:56.000Z
resources/sql/postgres/getTableMeta.sql
sitch/schemats
48dcb378f3beacf8a7b5e528bc22832e8a25b43a
[ "MIT" ]
null
null
null
resources/sql/postgres/getTableMeta.sql
sitch/schemats
48dcb378f3beacf8a7b5e528bc22832e8a25b43a
[ "MIT" ]
null
null
null
SELECT pg_tables.schemaname , pg_tables.TABLENAME , pg_attribute.attname AS field , format_type(pg_attribute.atttypid , NULL) AS "type" , pg_attribute.atttypmod AS len , ( SELECT col_description(pg_attribute.attrelid , pg_attribute.attnum)) AS COMMENT , CASE pg_attribute.attnotnull WHEN FALSE THEN 1 ELSE 0 END AS "notnull" , pg_constraint.conname AS "key" , pc2.conname AS ckey , ( SELECT pg_attrdef.adsrc FROM pg_attrdef WHERE pg_attrdef.adrelid = pg_class.oid AND pg_attrdef.adnum = pg_attribute.attnum) AS def FROM pg_tables , pg_class JOIN pg_attribute ON pg_class.oid = pg_attribute.attrelid AND pg_attribute.attnum > 0 LEFT JOIN pg_constraint ON pg_constraint.contype = 'p'::"char" AND pg_constraint.conrelid = pg_class.oid AND (pg_attribute.attnum = ANY (pg_constraint.conkey)) LEFT JOIN pg_constraint AS pc2 ON pc2.contype = 'f'::"char" AND pc2.conrelid = pg_class.oid AND (pg_attribute.attnum = ANY (pc2.conkey)) WHERE pg_class.relname = pg_tables.TABLENAME AND pg_tables.schemaname IN ('op' , 'im' , 'cs' , 'usr' , 'li') -- AND pg_tables.tableowner = "current_user"() AND pg_attribute.atttypid <> 0::oid ---AND TABLENAME = $1 ORDER BY pg_tables.schemaname , pg_tables.TABLENAME ASC;
32.613636
114
0.643902
06c721405e483d85ceca8a1fee1d7edcb94ac074
976
swift
Swift
Tests/SwiftyFirestoreTests/Assets/FirestoreRelationAlias.swift
YusukeHosonuma/FirestoreSwifty
5a330af5746bb2aad352c180020f76fb23fa8a61
[ "MIT" ]
2
2020-04-19T10:28:01.000Z
2021-01-04T16:16:50.000Z
Tests/SwiftyFirestoreTests/Assets/FirestoreRelationAlias.swift
YusukeHosonuma/FirestoreSwifty
5a330af5746bb2aad352c180020f76fb23fa8a61
[ "MIT" ]
6
2020-04-02T09:07:21.000Z
2022-01-22T11:21:42.000Z
Tests/SwiftyFirestoreTests/Assets/FirestoreRelationAlias.swift
YusukeHosonuma/FirestoreSwifty
5a330af5746bb2aad352c180020f76fb23fa8a61
[ "MIT" ]
1
2020-06-14T13:24:46.000Z
2020-06-14T13:24:46.000Z
// // Firestore+relation.swift // SwiftyFirestore // // Created by Yusuke Hosonuma on 2020/04/02. // Copyright © 2020 Yusuke Hosonuma. All rights reserved. // import SwiftyFirestore // // 📄 Data structure // // { // todos: <TodoDocument> [], // gist: <GistDocument> [], // account: <AccountDocument> [ // <id>: { // repository: <RepositoryDocument> [] // } // ] // } // /* // MARK: Root extension RootRef { var todos: CollectionRef<TodoDocument> { CollectionRef(ref) } var gist: CollectionRef<GistDocument> { CollectionRef(ref) } var account: CollectionRef<AccountDocument> { CollectionRef(ref) } } // MARK: Account extension DocumentRef where Document == AccountDocument { var repository: CollectionRef<RepositoryDocument> { CollectionRef(ref) } } // MARK: CollectionGroups extension CollectionGroups { var repository: CollectionGroupRef<RepositoryDocument> { CollectionGroupRef() } } */
21.217391
83
0.654713
3ca33247a44e507a09fec91d08d23d2e52857ccc
2,239
lua
Lua
test_scripts/RC/CLIMATE_RADIO/OnRemoteControlSettings/024_Allowed_false_no_PTU.lua
shiniwat/sdl_atf_test_scripts
7e8686f682ea0fac7ba1ba53d380c842a6434875
[ "BSD-3-Clause" ]
3
2016-03-17T02:26:56.000Z
2021-11-06T08:04:19.000Z
test_scripts/RC/CLIMATE_RADIO/OnRemoteControlSettings/024_Allowed_false_no_PTU.lua
shiniwat/sdl_atf_test_scripts
7e8686f682ea0fac7ba1ba53d380c842a6434875
[ "BSD-3-Clause" ]
1,335
2016-03-14T18:29:40.000Z
2022-03-30T10:40:28.000Z
test_scripts/RC/CLIMATE_RADIO/OnRemoteControlSettings/024_Allowed_false_no_PTU.lua
shiniwat/sdl_atf_test_scripts
7e8686f682ea0fac7ba1ba53d380c842a6434875
[ "BSD-3-Clause" ]
72
2016-03-30T13:44:17.000Z
2021-07-26T06:48:24.000Z
--------------------------------------------------------------------------------------------------- -- User story: https://github.com/smartdevicelink/sdl_requirements/issues/11 -- Use case: https://github.com/smartdevicelink/sdl_requirements/blob/master/detailed_docs/rc_enabling_disabling.md -- Item: Use Case 1: Main Flow (updates https://github.com/smartdevicelink/sdl_core/issues/2173) -- -- Requirement summary: -- [SDL_RC] Resource allocation based on access mode -- -- Description: -- In case: -- SDL received OnRemoteControlSettings (allowed:false) from HMI -- -- SDL must: -- 1) store RC state allowed:false internally -- 2) keep all applications with appHMIType REMOTE_CONTROL registered and in current HMI levels --------------------------------------------------------------------------------------------------- --[[ Required Shared libraries ]] local runner = require('user_modules/script_runner') local commonRC = require('test_scripts/RC/commonRC') --[[ Test Configuration ]] runner.testSettings.isSelfIncluded = false --[[ General configuration parameters ]] config.application1.registerAppInterfaceParams.appHMIType = { "REMOTE_CONTROL" } config.application2.registerAppInterfaceParams.appHMIType = { "REMOTE_CONTROL" } config.application3.registerAppInterfaceParams.appHMIType = { "DEFAULT" } --[[ Local Functions ]] local function disableRCFromHMI() commonRC.defineRAMode(false, nil) commonRC.getMobileSession():ExpectNotification("OnHMIStatus") :Times(0) commonRC.getMobileSession(2):ExpectNotification("OnHMIStatus") :Times(0) commonRC.getMobileSession(3):ExpectNotification("OnHMIStatus") :Times(0) EXPECT_HMINOTIFICATION("BasicCommunication.OnAppUnregistered") :Times(0) commonRC.wait(commonRC.timeout) end --[[ Scenario ]] runner.Title("Preconditions") runner.Step("Clean environment", commonRC.preconditions) runner.Step("Start SDL, HMI, connect Mobile, start Session", commonRC.start) for i = 1, 3 do runner.Step("RAI " .. i, commonRC.registerAppWOPTU, { i }) runner.Step("Activate App " .. i, commonRC.activateApp, { i }) end runner.Title("Test") runner.Step("Disable RC from HMI", disableRCFromHMI) runner.Title("Postconditions") runner.Step("Stop SDL", commonRC.postconditions)
37.316667
115
0.699866
6df554372f9b173312a18b65085fdca19d93bfbe
339
dart
Dart
lib/backend/api.dart
PrevenTech/client
1f831638be28bd5db53a65c761b838170812d641
[ "MIT" ]
null
null
null
lib/backend/api.dart
PrevenTech/client
1f831638be28bd5db53a65c761b838170812d641
[ "MIT" ]
6
2020-06-22T03:51:21.000Z
2020-06-24T04:49:15.000Z
lib/backend/api.dart
PrevenTech/client
1f831638be28bd5db53a65c761b838170812d641
[ "MIT" ]
null
null
null
import 'package:cloud_firestore/cloud_firestore.dart'; import 'package:preven_tech/location/libLocation.dart'; class Backend { static uploadData() { var locations = []; var userLocations = LocationRegistry.locations; userLocations.forEach((element) { locations.add({ 'latitude': element }); }); } }
24.214286
55
0.675516
6843fc20d6b82b4d2dda04de5c4e9baa7d11b130
3,513
html
HTML
src/app/shop/wishlist/wishlist.component.html
Metwalli/frontend
0c200d44c33495f0569fb94779411689a109f2f6
[ "MIT" ]
null
null
null
src/app/shop/wishlist/wishlist.component.html
Metwalli/frontend
0c200d44c33495f0569fb94779411689a109f2f6
[ "MIT" ]
null
null
null
src/app/shop/wishlist/wishlist.component.html
Metwalli/frontend
0c200d44c33495f0569fb94779411689a109f2f6
[ "MIT" ]
null
null
null
<app-breadcrumb [title]="'Wishlist'" [breadcrumb]="'Wishlist'"></app-breadcrumb> <!--section start--> <section class="wishlist-section section-b-space"> <div class="container"> <div class="col-md-12 empty-cart-cls text-center" *ngIf='!products.length'> <img src="assets/images/empty-wishlist.png" alt="Empty cart" title="Emprt cart"> <h3 class="mt-4"><b>Wishlist is Empty</b></h3> <h4>Explore more shortlist some items.</h4> </div> <div class="row" *ngIf='products.length'> <div class="col-sm-12"> <table class="table cart-table table-responsive-xs"> <thead> <tr class="table-head"> <th scope="col">image</th> <th scope="col">product name</th> <th scope="col">price</th> <th scope="col">availability</th> <th scope="col">action</th> </tr> </thead> <tbody *ngFor="let product of products"> <tr> <td> <a [routerLink]="['/shop/product/left/sidebar/', product.id]"> <img [src]="product.images[0].url" [alt]="product.images[0].alt" > </a> </td> <td> <a [routerLink]="['/shop/product/left/sidebar/', product.id]">{{ product.name | titlecase }}</a> <div class="mobile-cart-content row"> <div class="col-xs-3"> <p>{{ product.stock > 0 ? 'in stock' : 'out of stock' }}</p> </div> <div class="col-xs-3"> <h2 class="td-color"> {{ (product.price.salePrice | discount:product) | currency:settingsService?.localCurrency.currency:'symbol' }} </h2> </div> <div class="col-xs-3"> <h2 class="td-color"> <a href="javascript:void(0)" (click)="removeItem(product)" class="icon mr-1"> <i class="ti-close"></i> </a> <a [routerLink]="['/shop/cart']" (click)="addToCart(product)" class="cart"> <i class="ti-shopping-cart"></i> </a> </h2> </div> </div> </td> <td> <h2> {{ (product.price.salePrice) * product.price.salePrice | currency:settingsService?.localCurrency.currency:'symbol' }} </h2> </td> <td> <p>{{ product.stock > 0 ? 'in stock' : 'out of stock' }}</p> </td> <td> <a href="javascript:void(0)" (click)="removeItem(product)" class="icon mr-3"> <i class="ti-close"></i> </a> <a [routerLink]="['/shop/product/left/sidebar/', product.id]" class="cart"> <i class="ti-shopping-cart"></i> </a> </td> </tr> </tbody> </table> </div> </div> <div class="row wishlist-buttons" *ngIf='products.length'> <div class="col-12"> <a [routerLink]="['/shop/collection/left/sidebar']" class="btn btn-solid">continue shopping</a> <a [routerLink]="['/shop/checkout']" class="btn btn-solid">check out</a> </div> </div> </div> </section> <!--section end-->
43.37037
137
0.449473
e772dec8066509b9d700bfd2fe5c4f44bc395082
444
js
JavaScript
server/validation/create_session.js
marwajomaa/connect5
4dc5536b548a03b047a1b5302edf89744d4e3126
[ "MIT" ]
1
2018-12-23T23:32:03.000Z
2018-12-23T23:32:03.000Z
server/validation/create_session.js
marwajomaa/connect5
4dc5536b548a03b047a1b5302edf89744d4e3126
[ "MIT" ]
null
null
null
server/validation/create_session.js
marwajomaa/connect5
4dc5536b548a03b047a1b5302edf89744d4e3126
[ "MIT" ]
null
null
null
const Joi = require("joi"); const validate = data => new Promise((resolve, reject) => { const schema = Joi.object().keys({ sessionType: Joi.number().min(0).max(3).required(), startDate: Joi.date().required(), inviteesNumber: Joi.number().integer().min(0).required(), }); const result = Joi.validate(data, schema); return !result.error ? resolve() : reject(result.error.details[0].message) }); module.exports = validate;
27.75
76
0.65991
83f0acb96fe20d070491b37be92bceaea9d5c43c
5,102
java
Java
src/main/java/com/liferay/faces/util/el/ELResolverBase.java
liferay/liferay-faces-util
478650c317658760fd8075fceb0e4b329a33687d
[ "Apache-2.0" ]
4
2015-09-09T13:04:29.000Z
2020-10-26T01:10:14.000Z
src/main/java/com/liferay/faces/util/el/ELResolverBase.java
liferay/liferay-faces-util
478650c317658760fd8075fceb0e4b329a33687d
[ "Apache-2.0" ]
92
2015-10-21T21:26:51.000Z
2021-08-24T15:04:47.000Z
src/main/java/com/liferay/faces/util/el/ELResolverBase.java
liferay/liferay-faces-util
478650c317658760fd8075fceb0e4b329a33687d
[ "Apache-2.0" ]
9
2015-09-04T17:36:29.000Z
2021-06-29T18:51:21.000Z
/** * Copyright (c) 2000-2021 Liferay, Inc. All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.liferay.faces.util.el; import java.beans.FeatureDescriptor; import java.io.Serializable; import java.util.Arrays; import java.util.Collections; import java.util.Iterator; import java.util.List; import javax.el.ELContext; import javax.el.ELResolver; import javax.faces.application.Application; import org.osgi.annotation.versioning.ConsumerType; import com.liferay.faces.util.logging.Logger; import com.liferay.faces.util.logging.LoggerFactory; /** * This is a convenience base class that extends {@link ELResolver}. A subclasses must be designed to be instantiated as * a singleton because the JavaDoc for {@link Application#getELResolver()} indicates that an {@code ELResolver} should * be a singleton instance. This class implements the {@link Serializable} interface as a clue to subclasses that they * should implement a stateless, thread-safe singleton design. Subclasses should call the static {@link * #addFeatureDescriptor(String, Class)} method from a {@code static} block in order to add to the list of feature * descriptors. * * @author Neil Griffin */ @ConsumerType public abstract class ELResolverBase extends ELResolver implements Serializable { // Logger private static final Logger logger = LoggerFactory.getLogger(ELResolverBase.class); // serialVersionUID private static final long serialVersionUID = 8075201303544048292L; // Private Constants private final List<FeatureDescriptor> featureDescriptors; public ELResolverBase() { this.featureDescriptors = Collections.emptyList(); } protected ELResolverBase(FeatureDescriptor... featureDescriptors) { this.featureDescriptors = Collections.unmodifiableList(Arrays.asList(featureDescriptors)); } /** * @param featureName * @param classType * * @deprecated Use {@link #newFeatureDescriptor(java.lang.String, java.lang.Class)} and {@link * #ELResolverBase(java.beans.FeatureDescriptor...)} instead. */ @Deprecated protected static void addFeatureDescriptor(String featureName, Class<?> classType) { logger.warn( "Ignoring static call to addFeatureDescriptor(). To add feature descriptors use the protected constructor instead."); } protected static FeatureDescriptor newFeatureDescriptor(String featureName, Class<?> classType) { FeatureDescriptor featureDescriptor = new FeatureDescriptor(); featureDescriptor.setName(featureName); featureDescriptor.setDisplayName(featureName); featureDescriptor.setShortDescription(featureName); featureDescriptor.setExpert(false); featureDescriptor.setHidden(false); featureDescriptor.setPreferred(true); featureDescriptor.setValue(ELResolver.TYPE, classType); featureDescriptor.setValue(ELResolver.RESOLVABLE_AT_DESIGN_TIME, true); return featureDescriptor; } @Override public Iterator<FeatureDescriptor> getFeatureDescriptors(ELContext elContext, Object base) { return featureDescriptors.iterator(); } @Override public Class<?> getType(ELContext elContext, Object base, Object property) { if (elContext == null) { // Throw an exception as directed by the JavaDoc for ELContext. throw new NullPointerException("elContext may not be null"); } return String.class; } @Override public Object getValue(ELContext elContext, Object base, Object property) { if (elContext == null) { // Throw an exception as directed by the JavaDoc for ELContext. throw new NullPointerException("invalid ELContext"); } else { Object value = null; if (base == null) { if (property instanceof String) { String varName = (String) property; value = resolveVariable(elContext, varName); } } else { if (property instanceof String) { String propertyName = (String) property; value = resolveProperty(elContext, base, propertyName); } } if (value != null) { elContext.setPropertyResolved(true); } return value; } } @Override public boolean isReadOnly(ELContext elContext, Object base, Object property) { return true; } @Override public void setValue(ELContext elContext, Object base, Object property, Object value) { if (elContext == null) { // Throw an exception as directed by the JavaDoc for ELContext. throw new NullPointerException("elContext may not be null"); } } protected abstract Object resolveProperty(ELContext elContext, Object base, String property); protected abstract Object resolveVariable(ELContext elContext, String varName); }
31.109756
120
0.75441
fb9bdd41d0933e557bade63ddbc209d00a944283
5,138
java
Java
test-2018-12-10_OpenCV_CameraCalibration_2/src/com/github/smk7758/OpenCV_CameraCalibration/MatIO.java
smk7758/OpenCV_CameraCalibration
ee29c438ece9ff9646a2f4c0dd632da02425a76c
[ "Unlicense" ]
null
null
null
test-2018-12-10_OpenCV_CameraCalibration_2/src/com/github/smk7758/OpenCV_CameraCalibration/MatIO.java
smk7758/OpenCV_CameraCalibration
ee29c438ece9ff9646a2f4c0dd632da02425a76c
[ "Unlicense" ]
null
null
null
test-2018-12-10_OpenCV_CameraCalibration_2/src/com/github/smk7758/OpenCV_CameraCalibration/MatIO.java
smk7758/OpenCV_CameraCalibration
ee29c438ece9ff9646a2f4c0dd632da02425a76c
[ "Unlicense" ]
null
null
null
package com.github.smk7758.OpenCV_CameraCalibration; import java.io.BufferedWriter; import java.io.IOException; import java.nio.file.Files; import java.nio.file.Path; import java.util.HashMap; import java.util.Map; import java.util.Map.Entry; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; import javax.xml.transform.Transformer; import javax.xml.transform.TransformerConfigurationException; import javax.xml.transform.TransformerException; import javax.xml.transform.TransformerFactory; import javax.xml.transform.dom.DOMSource; import javax.xml.transform.stream.StreamResult; import org.opencv.core.CvType; import org.opencv.core.Mat; import org.w3c.dom.Document; import org.w3c.dom.Element; import org.w3c.dom.Node; import org.w3c.dom.NodeList; import org.xml.sax.SAXException; public class MatIO { public static Map<String, Mat> loadMat(Path filePath) { Document document = getDocument(filePath); Element root = document.getDocumentElement(); NodeList rootNodeList = root.getChildNodes(); Map<String, Mat> mats = new HashMap<>(); for (int i = 0; i < rootNodeList.getLength(); i++) { if (rootNodeList.item(i).getNodeType() == Node.ELEMENT_NODE) { mats.put(rootNodeList.item(i).getNodeName(), getMatElement(root, rootNodeList.item(i).getNodeName())); } } return mats; } private static Mat getMatElement(Element root, String matName) { NodeList matDataRoot = root.getElementsByTagName(matName); Element matDataElement = (Element) matDataRoot.item(0); final int rows = Integer.valueOf(matDataElement.getAttribute("rows")); final int cols = Integer.valueOf(matDataElement.getAttribute("cols")); final int channels = Integer.valueOf(matDataElement.getAttribute("channels")); final int dims = Integer.valueOf(matDataElement.getAttribute("dims")); // TODO String matDataString = matDataElement.getTextContent(); matDataString = matDataString.replaceAll("\\[", "").replaceAll("\\]", "").trim(); String[] matDataStringLines = matDataString.split(";"); Mat mat = new Mat(rows, cols, CvType.CV_32FC(channels)); for (int row = 0; row < rows; row++) { String[] matDataSplitted = matDataStringLines[row].split(","); for (int col = 0; col < cols; col++) { float[] matData = new float[channels]; for (int channel = 0; channel < channels; channel++) { System.out.println(matDataSplitted[col * channels + channel].trim()); matData[channel] = Integer.valueOf(matDataSplitted[col * channels + channel].trim()); System.out.println("matData[channel]: " + matData[channel]); } mat.put(row, col, matData); } } return mat; } private static Document getDocument(Path filePath) { Document document = null; try { DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); DocumentBuilder builder = factory.newDocumentBuilder(); document = builder.parse(filePath.toString()); } catch (ParserConfigurationException ex) { ex.printStackTrace(); } catch (SAXException ex) { ex.printStackTrace(); } catch (IOException ex) { ex.printStackTrace(); } return document; } public static void exportMat(Map<String, Mat> mats, Path filePath) { try { Document document = getDocument(); Element root = document.createElement("root"); document.appendChild(root); for (Entry<String, Mat> entryMat : mats.entrySet()) { final Element matData = setMatElement(document, entryMat.getKey(), entryMat.getValue()); root.appendChild(matData); } BufferedWriter bw = Files.newBufferedWriter(filePath); outputDocument(document, new StreamResult(bw)); } catch (IOException ex) { ex.printStackTrace(); } } private static Element setMatElement(Document document, String matName, Mat mat) { Element matData = document.createElement(matName); matData.setAttribute("rows", String.valueOf(mat.rows())); matData.setAttribute("cols", String.valueOf(mat.cols())); matData.setAttribute("channels", String.valueOf(mat.channels())); matData.setAttribute("dims", String.valueOf(mat.dims())); matData.setTextContent(mat.dump()); return matData; } private static Document getDocument() { DocumentBuilderFactory dbfactory = DocumentBuilderFactory.newInstance(); DocumentBuilder docbuilder = null; try { docbuilder = dbfactory.newDocumentBuilder(); } catch (ParserConfigurationException ex) { ex.printStackTrace(); } return docbuilder.newDocument(); } private static void outputDocument(Document document, StreamResult streamResult) { try { TransformerFactory tfactory = TransformerFactory.newInstance(); Transformer transformer = tfactory.newTransformer(); // transformer.setOutputProperty("method", "html"); //宣言無し transformer.setOutputProperty("indent", "yes"); // 改行指定 transformer.setOutputProperty("encoding", "SHIFT_JIS"); // encoding transformer.transform(new DOMSource(document), streamResult); } catch (TransformerConfigurationException ex) { ex.printStackTrace(); } catch (TransformerException ex) { ex.printStackTrace(); } } }
34.02649
106
0.735695
f18061d06f0e5ca6c0a0cb86e8f41d010d253881
88
dart
Dart
Foody/lib/screen/checkout/web/tablet/CheckoutWebTablet.dart
ABDULKARIMALBAIK/foody
8445995b0cc1ad09745eaaa3179fc20a818cbc40
[ "MIT" ]
1
2022-02-07T07:29:15.000Z
2022-02-07T07:29:15.000Z
Foody/lib/screen/checkout/web/tablet/CheckoutWebTablet.dart
ABDULKARIMALBAIK/foody
8445995b0cc1ad09745eaaa3179fc20a818cbc40
[ "MIT" ]
null
null
null
Foody/lib/screen/checkout/web/tablet/CheckoutWebTablet.dart
ABDULKARIMALBAIK/foody
8445995b0cc1ad09745eaaa3179fc20a818cbc40
[ "MIT" ]
1
2022-02-07T07:29:16.000Z
2022-02-07T07:29:16.000Z
I am so sorry , this code is not to sharing with github because it has sensitive data :)
88
88
0.761364
660ff9ae2df7b1b12391560418869ea99fb33a4b
1,093
cpp
C++
MainPL/TheMinimaGame.cpp
aajjbb/contest-files
b8842681b96017063a7baeac52ae1318bf59d74d
[ "Apache-2.0" ]
1
2018-08-28T19:58:40.000Z
2018-08-28T19:58:40.000Z
MainPL/TheMinimaGame.cpp
aajjbb/contest-files
b8842681b96017063a7baeac52ae1318bf59d74d
[ "Apache-2.0" ]
2
2017-04-16T00:48:05.000Z
2017-08-03T20:12:26.000Z
MainPL/TheMinimaGame.cpp
aajjbb/contest-files
b8842681b96017063a7baeac52ae1318bf59d74d
[ "Apache-2.0" ]
4
2016-03-04T19:42:00.000Z
2018-01-08T11:42:00.000Z
#include <iostream> #include <string> #include <sstream> #include <vector> #include <set> #include <map> #include <list> #include <queue> #include <stack> #include <memory> #include <iomanip> #include <numeric> #include <functional> #include <new> #include <algorithm> #include <cmath> #include <cstring> #include <cstdlib> #include <cstdio> #include <climits> #include <cctype> #include <ctime> template<typename T> T gcd(T a, T b) { if(!b) return a; return gcd(b, a % b); } template<typename T> T lcm(T a, T b) { return a * b / gcd(a, b); } template<typename T> void chmin(T& a, T b) { a = (a > b) ? b : a; } template<typename T> void chmax(T& a, T b) { a = (a < b) ? b : a; } int in() { int x; scanf("%d", &x); return x; } using namespace std; typedef long long Int; typedef unsigned uint; const int MAXN = 1000007; int N; int X[MAXN]; int main(void) { N = in(); int i; for (i = 0; i < N; i++) { X[i] = in(); } sort(X, X + N); int best = 0; for (int i = 0; i < N; i++) { best = max(best, X[i] - best); } printf("%d\n", best); return 0; }
16.313433
67
0.586459
04078f66e0ccd5063039bfe5afeae5873e2cd8eb
3,633
ps1
PowerShell
data/train/powershell/04078f66e0ccd5063039bfe5afeae5873e2cd8ebget-wttjobs.ps1
aliostad/deep-learning-lang-detection
d6b031f3ebc690cf2ffd0ae1b08ffa8fb3b38a62
[ "MIT" ]
84
2017-10-25T15:49:21.000Z
2021-11-28T21:25:54.000Z
data/train/powershell/04078f66e0ccd5063039bfe5afeae5873e2cd8ebget-wttjobs.ps1
vassalos/deep-learning-lang-detection
cbb00b3e81bed3a64553f9c6aa6138b2511e544e
[ "MIT" ]
5
2018-03-29T11:50:46.000Z
2021-04-26T13:33:18.000Z
data/train/powershell/04078f66e0ccd5063039bfe5afeae5873e2cd8ebget-wttjobs.ps1
vassalos/deep-learning-lang-detection
cbb00b3e81bed3a64553f9c6aa6138b2511e544e
[ "MIT" ]
24
2017-11-22T08:31:00.000Z
2022-03-27T01:22:31.000Z
param($query, $path, $category) # wtt global state $wttPath = $env:WTTSTDIO $identityDbName = "WTTIdentity" $dataStoreName = "WindowsPhone_Blue" $serverName = "WPCWTTBID01.redmond.corp.microsoft.com" # load the assemblies we need $asmBase = [Reflection.Assembly]::LoadFrom("$wttPath\WTTOMBase.dll") $asmIdentity = [Reflection.Assembly]::LoadFrom("$wttPath\WTTOMIdentity.dll") $asmJobs = [Reflection.Assembly]::LoadFrom("$wttPath\WTTOMJobs.dll") $asmAsset = [Reflection.Assembly]::LoadFrom("$wttPath\WTTOMAsset.dll") $asmResource = [Reflection.Assembly]::LoadFrom("$wttPath\WTTOMResource.dll") $asmParameter = [Reflection.Assembly]::LoadFrom("$wttPath\WTTOMParameter.dll") $typeJob = $asmJobs.GetType("Microsoft.DistributedAutomation.Jobs.Job") $typeDSUser = $asmBase.GetType("Microsoft.DistributedAutomation.DSUser") $typeMachine = $asmResource.GetType("Microsoft.DistributedAutomation.Asset.Resource") $typeResourceConfig = $asmResource.GetType("Microsoft.DistributedAutomation.Asset.ResourceConfiguration") function get-PathQuery { param($path) $jobQuery = New-Object Microsoft.DistributedAutomation.Query $typeJob $jobQuery.AddExpression("FullPath", "BeginsWith", $path) $jobQuery } function get-NameQuery($name) { $jobQuery = New-Object Microsoft.DistributedAutomation.Query $typeJob write-host $name $jobQuery.AddExpression("Name", "Equals", $name) $jobQuery } function get-CategoryQuery { param($path) $jobQuery = New-Object Microsoft.DistributedAutomation.Query $typeJob $jobQuery.AddExpression("FullPath", "BeginsWith", $path) $jobQuery } function get-PsqQuery { param($path) [void][Reflection.Assembly]::LoadFrom("$env:_WINPHONEROOT\src\tools\testinfra\product\wttmobile\wttexternal\studio\microsoft.wtt.ui.controls.objectcontrols.dll"); [void][Reflection.Assembly]::LoadFrom("$env:PROGRAMFILES\WTT 2.2\Studio\Tools\TuxNetSuiteUpdater\WtqHelper.dll") #[void][Reflection.Assembly]::LoadFrom("$env:PROGRAMFILES\Texus\Shell\microsoft.wtt.ui.controls.objectcontrols.dll"); #[void][Reflection.Assembly]::LoadFrom("$env:_WINPHONEROOT\developr\scyost\monad\wttsdk\wtqhelper.dll") $wtq = New-Object Microsoft.DistributedAutomation.Mobile.WtqHelper $path $query = $wtq.GetQuery( $dataStore, $typeJob ); $query } # alias some common WTT types that we will use $conjunction = [Microsoft.DistributedAutomation.Conjunction] $enterprise = [Microsoft.DistributedAutomation.Enterprise] $jobsDefinitionDataStore = [Microsoft.DistributedAutomation.Jobs.JobsDefinitionDataStore] $queryOperator = [Microsoft.DistributedAutomation.QueryOperator] $sortDirection = [Microsoft.DistributedAutomation.SortDirection] # set up the connection string to the identity database $identityInfo = New-Object Microsoft.DistributedAutomation.SqlIdentityConnectInfo $serverName, $identityDbName write-progress -activity "getting jobs" -status "Connecting to datastore" $global:dataStore = $enterprise::Connect($dataStoreName, $jobsDefinitionDataStore::ServiceName, $identityInfo) if ($path) { $jobQuery = get-pathquery $path } elseif ($query) { $jobQuery = get-psqQuery $query } elseif ($name) { $jobQuery = get-nameQuery $name } # todo: don't execute the query if there were failures in the script write-progress -activity "getting jobs" -status "Executing Query" $jobs = $dataStore.Query($jobQuery) write-progress -activity "getting jobs" -status "Done" $jobs
34.932692
166
0.728324
233d84ef42117ff3f93828730da65d30b9a9e619
471
dart
Dart
demo/lib/main_demo_1.dart
fuzongjian/DartNotes
23c8921d6d0d47cb96bf95c2790479d93c319615
[ "MIT" ]
null
null
null
demo/lib/main_demo_1.dart
fuzongjian/DartNotes
23c8921d6d0d47cb96bf95c2790479d93c319615
[ "MIT" ]
null
null
null
demo/lib/main_demo_1.dart
fuzongjian/DartNotes
23c8921d6d0d47cb96bf95c2790479d93c319615
[ "MIT" ]
null
null
null
import 'package:flutter/material.dart'; /// 入口文件、自定义组件 void main() { runApp(MyApp()); } // 自定义一个组件 class MyApp extends StatelessWidget { @override Widget build(BuildContext context) { return const Center( child: Text( 'Hello flutter ~', textDirection: TextDirection.ltr, style: TextStyle( fontSize: 40.0, // color: Colors.red, color: Color.fromRGBO(244, 12, 12, 0.5)), ), ); } }
18.84
53
0.573248
394c7ed6b9fd5f1eb65a4b134370ab8453d1e4d3
345
asm
Assembly
programs/oeis/188/A188510.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
22
2018-02-06T19:19:31.000Z
2022-01-17T21:53:31.000Z
programs/oeis/188/A188510.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
41
2021-02-22T19:00:34.000Z
2021-08-28T10:47:47.000Z
programs/oeis/188/A188510.asm
neoneye/loda
afe9559fb53ee12e3040da54bd6aa47283e0d9ec
[ "Apache-2.0" ]
5
2021-02-24T21:14:16.000Z
2021-08-09T19:48:05.000Z
; A188510: Expansion of x*(1 + x^2)/(1 + x^4) in powers of x. ; 0,1,0,1,0,-1,0,-1,0,1,0,1,0,-1,0,-1,0,1,0,1,0,-1,0,-1,0,1,0,1,0,-1,0,-1,0,1,0,1,0,-1,0,-1,0,1,0,1,0,-1,0,-1,0,1,0,1,0,-1,0,-1,0,1,0,1,0,-1,0,-1,0,1,0,1,0,-1,0,-1,0,1,0,1,0,-1,0,-1,0,1,0,1,0,-1,0,-1,0,1,0,1,0,-1,0,-1,0,1,0,1 sub $0,1 mod $0,8 sub $0,3 mod $0,2 sub $1,$0 mov $0,$1
34.5
225
0.481159
68151d3d666a9f7af0d7c2b8feacc9a98f4142da
7,958
html
HTML
index.html
omarnyte/Portfolio
e9ea8446d91a37e26b635cc8ff80180ad7dad026
[ "CC-BY-3.0" ]
null
null
null
index.html
omarnyte/Portfolio
e9ea8446d91a37e26b635cc8ff80180ad7dad026
[ "CC-BY-3.0" ]
null
null
null
index.html
omarnyte/Portfolio
e9ea8446d91a37e26b635cc8ff80180ad7dad026
[ "CC-BY-3.0" ]
null
null
null
<!DOCTYPE HTML> <html> <head> <!-- Global site tag (gtag.js) - Google Analytics --> <script async src="https://www.googletagmanager.com/gtag/js?id=UA-112513105-1"></script> <script> window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'UA-112513105-1'); </script> <title>Omar De Los Santos</title> <meta charset="utf-8"/> <meta name="viewport" content="width=device-width, initial-scale=1" /> <link rel="stylesheet" href="assets/css/main.css" /> <link rel="stylesheet" href="assets/css/additional.css" /> <link rel="stylesheet" href="https://cdn.rawgit.com/konpa/devicon/df6431e323547add1b4cf45992913f15286456d3/devicon.min.css"> <link href="https://fonts.googleapis.com/css?family=Poiret+One" rel="stylesheet"> </head> <body> <!-- Header --> <header id="header" class="alt"> <div class="inner"> <h1>Omar De Los Santos</h1> <p>Software Developer</p> </div> </header> <!-- Wrapper --> <div id="wrapper"> <!-- Banner --> <section id="intro" class="main"> <h2>Skills</h2> <div class="skills"> <div class="skill"> <span class="i devicon-babel-plain colored"></span> <span>Babel</span> </div> <div class="skill"> <span class="i devicon-css3-plain colored"></span> <span>CSS3</span> </div> <div class="skill"> <span class="i devicon-express-original colored"></span> <span>Express</span> </div> <div class="skill"> <span class="i devicon-git-plain colored"></span> <span>Git</span> </div> <div class="skill"> <span class="i devicon-heroku-original colored"></span> <span>Heroku</span> </div> <div class="skill"> <span class="i devicon-html5-plain colored"></span> <span>HTML5</span> </div> <div class="skill"> <span class="i devicon-javascript-plain colored"></span> <span>JavaScript</span> </div> <div class="skill"> <span class="i devicon-jquery-plain colored"></span> <span>jQuery</span> </div> <div class="skill"> <span class="i devicon-mongodb-plain colored"></span> <span>MongoDB</span> </div> <div class="skill"> <span class="i devicon-nodejs-plain colored"></span> <span>Node.js</span> </div> <div class="skill"> <span class="i devicon-photoshop-plain colored"></span> <span>Photoshop</span> </div> <div class="skill"> <span class="i devicon-postgresql-plain colored"></span> <span>PostgreSQL</span> </div> <div class="skill"> <span class="i devicon-rails-plain colored"></span> <span>Rails</span> </div> <div class="skill"> <span class="i devicon-react-original colored"></span> <span>React-Redux</span> </div> <div class="skill"> <span class="i devicon-ruby-plain colored"></span> <span>Ruby</span> </div> <div class="skill"> <span class="i devicon-webpack-plain colored"></span> <span>Webpack</span> </div> </div> <!-- <h2>Magna porta maximus</h2> <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed vitae<br /> malesuada turpis. Nam pellentesque in ac aliquam. Aliquam tempor<br /> mi porta egestas maximus lorem ipsum dolor.</p> <ul class="actions"> <li><a href="#" class="button big">Learn More</a></li> </ul> --> </section> <!-- Items --> <section class="main items"> <article class="item"> <header> <a><img src="images/bandstand.jpg" alt="" /></a> <h3>bandstand</h3> </header> <p>Single-page app, inspired by bandcamp.com, that empowers users to discover new artists and stream music directly from the app. The backend is built on Ruby on Rails with a PostgreSQL database. The frontend is built with React-Redux. It enlists an inordinate amount of tech-related puns.</p> <ul class="actions"> <li><a href="http://bandstandfullstack.herokuapp.com" target="_blank" class="button">Live Link</a></li> <li><a href="https://github.com/omarnyte/bandstand" target="_blank" class="button">GitHub</a></li> </ul> </article> <article class="item"> <header> <a href="#"><img src="images/spotifynder.jpg" alt="" /></a> <h3>Spotifynder</h3> </header> <p>Interactive visualization of related artists utilizing the Spotify API. All visuals are created using HTML, CSS, and vanilla JavaScript. On Google Chrome, users can search for artists with voice search, enabled by the browser's voice recognition..</p> <ul class="actions"> <li><a href="http://spotifynder.herokuapp.com" target="_blank" class="button">Live Link</a></li> <li><a href="https://github.com/omarnyte/Spotifynder" target="_blank" class="button">GitHub</a></li> </ul> </article> <article class="item"> <header> <a><img src="images/troubador.jpg" alt="" /></a> <h3>Troubador</h3> </header> <p>Practical iOS application that facilitates both impromptu and structured song-writing. Users can create and save written and audio notes stored directly on their device. I built the backend on Node.js/Express with a MongoDB database. </p> <ul class="actions"> <li><a href="https://shmmod.github.io/troubadour/" target="_blank" class="button">Live Link</a></li> <li><a href="https://github.com/SHMMOD " target="_blank" class="button">GitHub</a></li> </ul> </article> </section> <!-- Main --> <section id="main" class="main"> <header> <h2>About Me</h2> </header> <p>I'm a Los Angeles native who likes to move around a lot. I graduated from Yale University in 2015. Immediately after graduation, I devoted two years to an immigration nonprofit, where I advised low-income immigrants in New York City and represented them in their applications for immigration relief. In 2017, I moved back to California to pursue software development full time. Today, I am looking for an opportunity to code while creating a positive impact in the world.</p> <p>When I'm away from my computer, you'll find me making groan-worthy puns, reading realistic fiction, or petting my cat--Purrnie Sanders.</p> </section> <!-- CTA --> <section id="cta" class="main special"> <h2>Interested in Hiring?</h2> <!-- <p>Phasellus ac augue ac magna auctor tempus proin<br /> accumsan lacus a nibh commodo in pellentesque dui<br /> in hac habitasse platea dictumst.</p> --> <ul class="actions"> <li><a href="assets/resume.pdf" download="Resume - Omar De Los Santos.pdf" class="button big">Download Resume</a></li> </ul> </section> <!-- Footer --> <footer id="footer"> <ul class="icons"> <li><a href="mailto:omar.dlsg@gmail.com" class="icon fa-envelope"><span class="label">Email</span></a></li> <li><a href="https://github.com/omarnyte" target="_blank" class="icon fa-github"><span class="label">GitHub</span></a></li> <li><a href="https://www.linkedin.com/in/omardls/" target="_blank" class="icon fa-linkedin"><span class="label">LinkedIn</span></a></li> </ul> </footer> --> </div> <!-- Scripts --> <script src="assets/js/jquery.min.js"></script> <script src="assets/js/skel.min.js"></script> <script src="assets/js/util.js"></script> <script src="assets/js/main.js"></script> </body> </html>
39.98995
485
0.593491
6d27169fb1af05693975469dbfe8965d73e7d852
683
swift
Swift
Code/Http/Model/MQIEachKeyword.swift
13071159748/FYXM
c090216f395c8d0c91f0752516bd777df0bc5634
[ "MIT" ]
null
null
null
Code/Http/Model/MQIEachKeyword.swift
13071159748/FYXM
c090216f395c8d0c91f0752516bd777df0bc5634
[ "MIT" ]
null
null
null
Code/Http/Model/MQIEachKeyword.swift
13071159748/FYXM
c090216f395c8d0c91f0752516bd777df0bc5634
[ "MIT" ]
null
null
null
// // MQIEaMQIeyword.swift // XSDQReader // // Created by CQSC on 2018/7/4. // Copyright © 2018年 _CHK_ . All rights reserved. // import UIKit final class MQIEaMQIeyword: MQIBaseModel, ResponseCollectionSerializable { var key: String = "" static func collection(from response: HTTPURLResponse, withRepresentation representation: Any) -> [MQIEaMQIeyword] { var array = [MQIEaMQIeyword]() if let representation = representation as? [String] { for s in representation { let obj = MQIEaMQIeyword() obj.key = s array.append(obj) } } return array } }
23.551724
120
0.594436
36d54dfd52be6f30dd37bb274a41a9bd91ed3b34
3,502
swift
Swift
FoodViewer/Coordinators/DietSelectorCoordinator.swift
aleene/FoodViewer
d67a50d9da872a8b45a029d4c24e23301c6bcf32
[ "Apache-2.0" ]
12
2017-08-15T16:46:52.000Z
2019-11-05T19:47:14.000Z
FoodViewer/Coordinators/DietSelectorCoordinator.swift
aleene/FoodViewer
d67a50d9da872a8b45a029d4c24e23301c6bcf32
[ "Apache-2.0" ]
1,081
2016-03-25T17:14:51.000Z
2021-06-08T12:48:41.000Z
FoodViewer/Coordinators/DietSelectorCoordinator.swift
aleene/FoodViewer
d67a50d9da872a8b45a029d4c24e23301c6bcf32
[ "Apache-2.0" ]
9
2016-06-16T11:50:00.000Z
2021-03-06T22:16:45.000Z
// // DietSelectorCoordinator.swift // FoodViewer // // Created by arnaud on 17/02/2020. // Copyright © 2020 Hovering Above. All rights reserved. // import UIKit /** This class coordinates the viewControllers initiated by `DietSelectorCoordinator` and their corresponding interaction flow. The interaction flow between the parent coordinator and this coordinator is handled by the parent coordinator through a extension. This interaction flow is defined as a protocol in the viewController coordinated by THIS class. - Important The parent coordinator must be passed on to the coordinated viewController and will be used for any protocol methods. Variables: - `parentCoordinator`: the parent is the owner of this coordinator and the root for the associated viewController; - `childCoordinators`: the other coordinators that are required in child viewControllers; - `viewController`: the `DietSelectorTableViewController` that is managed; Functions: - `init(with:)` the initalisation method of this coordinator AND the corresponding viewController. - Parameter : the parent Coordinator; - `show()` - show the managed viewController from the parent viewController view stack. The viewController is push on a navigation controller. Managed viewControllers: - `ShowDietTriggersTableViewController`: allows to show a diet in detail. No protocol is needed as the user go back via the Back button */ final class DietSelectorCoordinator: Coordinator { weak var parentCoordinator: Coordinator? = nil var childCoordinators: [Coordinator] = [] var viewController: UIViewController? = nil private var coordinatorViewController: DietSelectorTableViewController? { self.viewController as? DietSelectorTableViewController } init(with coordinator:Coordinator?) { self.viewController = DietSelectorTableViewController.instantiate() self.coordinatorViewController?.coordinator = self self.parentCoordinator = coordinator } func show() { if let parent = parentCoordinator as? SettingsCoordinator { parent.presentAsPush(viewController) } } func showDiet(with index: Int?) { let coordinator = ShowDietTriggersCoordinator.init(with: self, diet: index) childCoordinators.append(coordinator) coordinator.show() } func presentAsPush(_ viewController: UIViewController?) { guard let validViewController = viewController else { return } //viewController.modalPresentationStyle = .overFullScreen if let nav = self.viewController?.navigationController { nav.pushViewController(validViewController, animated: true) } } /// The viewController informs its owner that it has disappeared func viewControllerDidDisappear(_ sender: UIViewController) { if self.childCoordinators.isEmpty { self.viewController = nil informParent() } } /// A child coordinator informs its owner that it has disappeared func canDisappear(_ coordinator: Coordinator) { if let index = self.childCoordinators.lastIndex(where: ({ $0 === coordinator }) ) { self.childCoordinators.remove(at: index) informParent() } } private func informParent() { if self.childCoordinators.isEmpty && self.viewController == nil { parentCoordinator?.canDisappear(self) } } }
37.255319
227
0.712736
2cdd114052d4f12c5f73c55d39ccefcb0dbe098c
5,414
swift
Swift
Sources/Server/Providers/SocketProviderData.swift
reaumur/ReaumurServer
943116f73e404d09a3c57b2a4383fb9b3b2db923
[ "MIT" ]
1
2018-05-29T02:53:55.000Z
2018-05-29T02:53:55.000Z
Sources/Server/Providers/SocketProviderData.swift
reaumur/ReaumurServer
943116f73e404d09a3c57b2a4383fb9b3b2db923
[ "MIT" ]
null
null
null
Sources/Server/Providers/SocketProviderData.swift
reaumur/ReaumurServer
943116f73e404d09a3c57b2a4383fb9b3b2db923
[ "MIT" ]
null
null
null
// // SocketProviderData.swift // Server // // Created by BluDesign, LLC on 5/13/18. // import Foundation import MongoKitten protocol SocketDataEncodable: Encodable { var socketFrame: SocketFrame { get } var type: SocketFrameHolder.FrameType { get } } extension SocketDataEncodable { var socketFrameHodler: SocketFrameHolder { return SocketFrameHolder(type: type, data: socketFrame) } var jsonValue: Any? { guard let data = try? JSONEncoder().encode(self) else { return nil } return try? JSONSerialization.jsonObject(with: data, options: .init(rawValue: 0)) } } struct ContainerFrame: Codable, SocketDataEncodable { let objectId: ObjectId let averageTemperature: Double? let averageHumidity: Double? let isHeating: Bool? let isCooling: Bool? let fanActive: Bool? let updatedAt: Date? let lastActionDate: Date? var socketFrame: SocketFrame { return .container(container: self) } var type: SocketFrameHolder.FrameType { return .container } } struct TemperatureFrame: Codable, SocketDataEncodable { let objectId: ObjectId let deviceId: String let createdAt: Date let temperature: Double let interval: Int let humididty: Double? let container: ContainerFrame? var socketFrame: SocketFrame { return .temperature(temperature: self) } var type: SocketFrameHolder.FrameType { return .temperature } } struct CycleFrame: Codable, SocketDataEncodable { let objectId: ObjectId let deviceId: String let createdAt: Date let turnedOn: Bool let container: ContainerFrame? var socketFrame: SocketFrame { return .cycle(cycle: self) } var type: SocketFrameHolder.FrameType { return .cycle } } struct HostDeviceFrame: Codable, SocketDataEncodable { let objectId: ObjectId let updatedAt: Date? let pingedAt: Date? let offline: Bool? var socketFrame: SocketFrame { return .hostDevice(hostDevice: self) } var type: SocketFrameHolder.FrameType { return .hostDevice } } struct DeviceFrame: Codable, SocketDataEncodable { let objectId: ObjectId let turnedOn: Bool? let lastTemperature: Double? let lastHumidity: Double? let lastActionDate: Date? let updatedAt: Date? let offline: Bool? let assigned: Bool? let outsideTemperature: Bool? var socketFrame: SocketFrame { return .device(device: self) } var type: SocketFrameHolder.FrameType { return .device } } enum SocketFrame { case temperature(temperature: TemperatureFrame) case cycle(cycle: CycleFrame) case hostDevice(hostDevice: HostDeviceFrame) case container(container: ContainerFrame) case device(device: DeviceFrame) var jsonValue: Any? { switch self { case let .temperature(socketData): return socketData.jsonValue case let .cycle(socketData): return socketData.jsonValue case let .hostDevice(socketData): return socketData.jsonValue case let .container(socketData): return socketData.jsonValue case let .device(socketData): return socketData.jsonValue } } } struct SocketFrameHolder: Codable { enum FrameType: Int, Codable { case ping = 1 case pong = 2 case temperature = 3 case cycle = 4 case hostDevice = 5 case container = 6 case device = 7 } enum CodingKeys: String, CodingKey { case type case data } let type: FrameType let data: SocketFrame? init(type: FrameType, data: SocketFrame? = nil) { self.type = type self.data = data } init(from decoder: Decoder) throws { let container = try decoder.container(keyedBy: CodingKeys.self) type = try container.decode(FrameType.self, forKey: .type) switch type { case .temperature: data = try? container.decode(TemperatureFrame.self, forKey: .data).socketFrame case .cycle: data = try? container.decode(CycleFrame.self, forKey: .data).socketFrame case .hostDevice: data = try? container.decode(HostDeviceFrame.self, forKey: .data).socketFrame case .container: data = try? container.decode(ContainerFrame.self, forKey: .data).socketFrame case .device: data = try? container.decode(DeviceFrame.self, forKey: .data).socketFrame default: data = nil } } func encode(to encoder: Encoder) throws { var container = encoder.container(keyedBy: CodingKeys.self) try container.encode(type, forKey: .type) if let data = data { switch data { case let .temperature(socketData): try container.encode(socketData, forKey: .data) case let .cycle(socketData): try container.encode(socketData, forKey: .data) case let .hostDevice(socketData): try container.encode(socketData, forKey: .data) case let .container(socketData): try container.encode(socketData, forKey: .data) case let .device(socketData): try container.encode(socketData, forKey: .data) } } } var stringValue: String? { guard let data = try? JSONEncoder().encode(self) else { return nil } return String(data: data, encoding: .utf8) } }
29.423913
105
0.657185
e86c64e4402ee3dc4ddd3bca9e889fdedf01eb29
16,218
cpp
C++
groups/bsl/bslx/bslx_marshallingutil.cpp
seanbaxter/bde-1
149176ebc2ae49c3b563895a7332fe638a760782
[ "Apache-2.0" ]
26
2015-05-07T04:22:06.000Z
2022-01-26T09:10:12.000Z
groups/bsl/bslx/bslx_marshallingutil.cpp
seanbaxter/bde-1
149176ebc2ae49c3b563895a7332fe638a760782
[ "Apache-2.0" ]
3
2015-05-07T21:06:36.000Z
2015-08-28T20:02:18.000Z
groups/bsl/bslx/bslx_marshallingutil.cpp
seanbaxter/bde-1
149176ebc2ae49c3b563895a7332fe638a760782
[ "Apache-2.0" ]
12
2015-05-06T08:41:07.000Z
2021-11-09T12:52:19.000Z
// bslx_marshallingutil.cpp -*-C++-*- #include <bslx_marshallingutil.h> #include <bsls_ident.h> BSLS_IDENT_RCSID(bslx_marshallingutil_cpp,"$Id$ $CSID$") namespace BloombergLP { namespace bslx { // ---------------------- // struct MarshallingUtil // ---------------------- // CLASS METHODS // *** put arrays of integral values *** void MarshallingUtil::putArrayInt64(char *buffer, const bsls::Types::Int64 *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const bsls::Types::Int64 *end = values + numValues; for (; values != end; ++values) { putInt64(buffer, *values); buffer += k_SIZEOF_INT64; } } void MarshallingUtil::putArrayInt64(char *buffer, const bsls::Types::Uint64 *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const bsls::Types::Uint64 *end = values + numValues; for (; values != end; ++values) { putInt64(buffer, *values); buffer += k_SIZEOF_INT64; } } void MarshallingUtil::putArrayInt56(char *buffer, const bsls::Types::Int64 *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const bsls::Types::Int64 *end = values + numValues; for (; values != end; ++values) { putInt56(buffer, *values); buffer += k_SIZEOF_INT56; } } void MarshallingUtil::putArrayInt56(char *buffer, const bsls::Types::Uint64 *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const bsls::Types::Uint64 *end = values + numValues; for (; values != end; ++values) { putInt56(buffer, *values); buffer += k_SIZEOF_INT56; } } void MarshallingUtil::putArrayInt48(char *buffer, const bsls::Types::Int64 *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const bsls::Types::Int64 *end = values + numValues; for (; values != end; ++values) { putInt48(buffer, *values); buffer += k_SIZEOF_INT48; } } void MarshallingUtil::putArrayInt48(char *buffer, const bsls::Types::Uint64 *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const bsls::Types::Uint64 *end = values + numValues; for (; values != end; ++values) { putInt48(buffer, *values); buffer += k_SIZEOF_INT48; } } void MarshallingUtil::putArrayInt40(char *buffer, const bsls::Types::Int64 *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const bsls::Types::Int64 *end = values + numValues; for (; values != end; ++values) { putInt40(buffer, *values); buffer += k_SIZEOF_INT40; } } void MarshallingUtil::putArrayInt40(char *buffer, const bsls::Types::Uint64 *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const bsls::Types::Uint64 *end = values + numValues; for (; values != end; ++values) { putInt40(buffer, *values); buffer += k_SIZEOF_INT40; } } void MarshallingUtil::putArrayInt32(char *buffer, const int *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const int *end = values + numValues; for (; values != end; ++values) { putInt32(buffer, *values); buffer += k_SIZEOF_INT32; } } void MarshallingUtil::putArrayInt32(char *buffer, const unsigned int *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const unsigned int *end = values + numValues; for (; values != end; ++values) { putInt32(buffer, *values); buffer += k_SIZEOF_INT32; } } void MarshallingUtil::putArrayInt24(char *buffer, const int *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const int *end = values + numValues; for (; values != end; ++values) { putInt24(buffer, *values); buffer += k_SIZEOF_INT24; } } void MarshallingUtil::putArrayInt24(char *buffer, const unsigned int *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const unsigned int *end = values + numValues; for (; values != end; ++values) { putInt24(buffer, *values); buffer += k_SIZEOF_INT24; } } void MarshallingUtil::putArrayInt16(char *buffer, const short *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const short *end = values + numValues; for (; values != end; ++values) { putInt16(buffer, *values); buffer += k_SIZEOF_INT16; } } void MarshallingUtil::putArrayInt16(char *buffer, const unsigned short *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const unsigned short *end = values + numValues; for (; values != end; ++values) { putInt16(buffer, *values); buffer += k_SIZEOF_INT16; } } // *** put arrays of floating-point values *** void MarshallingUtil::putArrayFloat64(char *buffer, const double *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const double *end = values + numValues; for (; values < end; ++values) { putFloat64(buffer, *values); buffer += k_SIZEOF_FLOAT64; } } void MarshallingUtil::putArrayFloat32(char *buffer, const float *values, int numValues) { BSLS_ASSERT(buffer); BSLS_ASSERT(values); BSLS_ASSERT(0 <= numValues); const float *end = values + numValues; for (; values < end; ++values) { putFloat32(buffer, *values); buffer += k_SIZEOF_FLOAT32; } } // *** get arrays of integral values *** void MarshallingUtil::getArrayInt64(bsls::Types::Int64 *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const bsls::Types::Int64 *end = variables + numVariables; for (; variables != end; ++variables) { getInt64(variables, buffer); buffer += k_SIZEOF_INT64; } } void MarshallingUtil::getArrayUint64(bsls::Types::Uint64 *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const bsls::Types::Uint64 *end = variables + numVariables; for (; variables != end; ++variables) { getUint64(variables, buffer); buffer += k_SIZEOF_INT64; } } void MarshallingUtil::getArrayInt56(bsls::Types::Int64 *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const bsls::Types::Int64 *end = variables + numVariables; for (; variables != end; ++variables) { getInt56(variables, buffer); buffer += k_SIZEOF_INT56; } } void MarshallingUtil::getArrayUint56(bsls::Types::Uint64 *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const bsls::Types::Uint64 *end = variables + numVariables; for (; variables != end; ++variables) { getUint56(variables, buffer); buffer += k_SIZEOF_INT56; } } void MarshallingUtil::getArrayInt48(bsls::Types::Int64 *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const bsls::Types::Int64 *end = variables + numVariables; for (; variables != end; ++variables) { getInt48(variables, buffer); buffer += k_SIZEOF_INT48; } } void MarshallingUtil::getArrayUint48(bsls::Types::Uint64 *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const bsls::Types::Uint64 *end = variables + numVariables; for (; variables != end; ++variables) { getUint48(variables, buffer); buffer += k_SIZEOF_INT48; } } void MarshallingUtil::getArrayInt40(bsls::Types::Int64 *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const bsls::Types::Int64 *end = variables + numVariables; for (; variables != end; ++variables) { getInt40(variables, buffer); buffer += k_SIZEOF_INT40; } } void MarshallingUtil::getArrayUint40(bsls::Types::Uint64 *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const bsls::Types::Uint64 *end = variables + numVariables; for (; variables != end; ++variables) { getUint40(variables, buffer); buffer += k_SIZEOF_INT40; } } void MarshallingUtil::getArrayInt32(int *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const int *end = variables + numVariables; for (; variables != end; ++variables) { getInt32(variables, buffer); buffer += k_SIZEOF_INT32; } } void MarshallingUtil::getArrayUint32(unsigned int *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const unsigned int *end = variables + numVariables; for (; variables != end; ++variables) { getUint32(variables, buffer); buffer += k_SIZEOF_INT32; } } void MarshallingUtil::getArrayInt24(int *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const int *end = variables + numVariables; for (; variables != end; ++variables) { getInt24(variables, buffer); buffer += k_SIZEOF_INT24; } } void MarshallingUtil::getArrayUint24(unsigned int *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const unsigned int *end = variables + numVariables; for (; variables != end; ++variables) { getUint24(variables, buffer); buffer += k_SIZEOF_INT24; } } void MarshallingUtil::getArrayInt16(short *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const short *end = variables + numVariables; for (; variables != end; ++variables) { getInt16(variables, buffer); buffer += k_SIZEOF_INT16; } } void MarshallingUtil::getArrayUint16(unsigned short *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const unsigned short *end = variables + numVariables; for (; variables != end; ++variables) { getUint16(variables, buffer); buffer += k_SIZEOF_INT16; } } // *** get arrays of floating-point variables *** void MarshallingUtil::getArrayFloat64(double *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const double *end = variables + numVariables; for (; variables != end; ++variables) { getFloat64(variables, buffer); buffer += k_SIZEOF_FLOAT64; } } void MarshallingUtil::getArrayFloat32(float *variables, const char *buffer, int numVariables) { BSLS_ASSERT(variables); BSLS_ASSERT(buffer); BSLS_ASSERT(0 <= numVariables); const float *end = variables + numVariables; for (; variables != end; ++variables) { getFloat32(variables, buffer); buffer += k_SIZEOF_INT32; } } } // close package namespace } // close enterprise namespace // ---------------------------------------------------------------------------- // Copyright 2014 Bloomberg Finance L.P. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. // ----------------------------- END-OF-FILE ----------------------------------
31.068966
79
0.517203
85c07ee464564bd2c4ec38ac710ea7ccb915d0a8
916
js
JavaScript
src/components/Objective/index.js
joshhunt/destinyCatwalk
d75cc7a24c0856ebba2e2a0d657c7c6472cc23a0
[ "MIT" ]
null
null
null
src/components/Objective/index.js
joshhunt/destinyCatwalk
d75cc7a24c0856ebba2e2a0d657c7c6472cc23a0
[ "MIT" ]
null
null
null
src/components/Objective/index.js
joshhunt/destinyCatwalk
d75cc7a24c0856ebba2e2a0d657c7c6472cc23a0
[ "MIT" ]
null
null
null
import React from 'react'; // <li key={objective.objectiveHash} data-hash={objective.objectiveHash}> // {objectiveDefs[objective.objectiveHash].progressDescription || 'Completed'}:{' '} // {objective.progress} / {objective.completionValue} // </li>; import s from './styles.styl'; export default function Objective({ objective, objectiveDef }) { const progress = Math.min(objective.progress / objective.completionValue, 1); const percent = progress * 100; return ( <div className={s.root}> <div className={s.track} style={{ width: `${percent}%` }} /> <div className={s.text}> <div className={s.name}> {objectiveDef.progressDescription || <em>Secret</em>} </div> <div className={s.progress}> {objective.progress}{' '} {!objective.complete && <span>/ {objective.completionValue}</span>} </div> </div> </div> ); }
30.533333
86
0.624454
0b191c0d32cab31c5200e641dbf5b0941ec0ef4d
4,768
ps1
PowerShell
Functions/Public/Watch-Connection.ps1
matthewjdegarmo/HelpDesk
c8e40f1db95e00ea95dfac2a1f631e349b72c25a
[ "MIT" ]
1
2020-10-01T13:06:53.000Z
2020-10-01T13:06:53.000Z
Functions/Public/Watch-Connection.ps1
matthewjdegarmo/HelpDesk
c8e40f1db95e00ea95dfac2a1f631e349b72c25a
[ "MIT" ]
5
2020-08-13T19:45:03.000Z
2021-11-23T15:35:27.000Z
Functions/Public/Watch-Connection.ps1
matthewjdegarmo/HelpDesk
c8e40f1db95e00ea95dfac2a1f631e349b72c25a
[ "MIT" ]
null
null
null
#Region Watch-Connection <# .SYNOPSIS Loops through a test-connection and sends email when connection is made. .DESCRIPTION This script simply is a test-connection that loops until a connection is made. .PARAMETER ComputerName This parameter should specify the computer name you are testing a connections with. .PARAMETER Message This parameter will include text to be included in the success email. .PARAMETER Recipients This parameter specifies additional recipients to receive the successful connection email. These values should be separated by commas and wrapped in quotation marks. .PARAMETER Email This switch allows the function to send an email when a successful connection is made. If this switch is present, an email will be sent. .PARAMETER From This is the email address that this alert will originate from. .PARAMETER SmtpServer This is the SMTP server that you will be using to send the email. .EXAMPLE PS>Watch-Connection -ComputerName SomeServer -Message "A connection to SomeServer has been made. Please remove admin access from user 'SomeUser'" -Recipients "myself@me.com","someoneelse@them.com","OtherEmailsSeperatedByCommas@site.com" Connecting to SOMESERVER.... Sending email to the following recipients: "myself@me.com","someoneelse@them.com","OtherEmailsSeperatedByCommas@site.com" Connection Successful. Message: A connection to SomeServer has been made. Please remove admin access from user 'SomeUser' Description ----------- This will loop through a Test-Connection -Count 1 command against 'SomeServer' until a connection is made. Once it is made, an email is sent to the user running the script and to the additional users specified in the -Recipients Parameter. .EXAMPLE PS>Watch-Connection SomeComputer -Notification "Finally connected to user 'SomeUser' PC." Connecting to SOMECOMPUTER.... Connection Successful. Message: Finally connected to user 'SomeUser' PC. Description ----------- This will loop through a `Test-Connection -Count 1` command against 'SomeComputer'. .NOTES Author: Matthew J. DeGarmo GitHub: https://github.com/matthewjdegarmo You can either submit a [PR](https://github.com/matthewjdegarmo/HelpDesk/pulls) or create an [Issue](https://github.com/matthewjdegarmo/HelpDesk/issues/new) on this GitHub project at https://github.com/matthewjdegarmo/HelpDesk #> Function Watch-Connection() { [cmdletbinding()] param( [parameter(Mandatory = $true, Position = 1)] [ValidateNotNullOrEmpty()] [string] $ComputerName, [string ]$Message, [string[]] $Recipients, [switch] $Email, [String] $From, [String] $SmtpServer ) begin { $ComputerName = $ComputerName.ToUpper() } process { try { DO { Clear-Host Write-Host "Connecting to $ComputerName." -ForegroundColor Yellow Start-Sleep -Milliseconds 500 Clear-Host Write-Host "Connecting to $ComputerName.." -ForegroundColor Yellow Start-Sleep -Milliseconds 500 Clear-Host Write-Host "Connecting to $ComputerName..." -ForegroundColor Yellow Start-Sleep -Milliseconds 500 Clear-Host Write-Host "Connecting to $ComputerName...." -ForegroundColor Yellow } while (-not(Test-Connection $ComputerName -count 1 -ErrorAction SilentlyContinue)) if (Test-Connection $ComputerName -count 1 -ErrorAction SilentlyContinue) { if ($Email.IsPresent) { $MessageArgs = @{ To = $Recipients From = $From Subject = "$ComputerName Online" SmtpServer = $SmtpServer Priority = 'High' Body = "$ComputerName is now online. <p>$Message</p> <p></p><n>From: $env:USERNAME</n> <p></p><n>Source: $env:COMPUTERNAME</n>" } Write-Output "Sending email to the following recipients: $Recipients" Send-MailMessage @MessageArgs -BodyAsHtml } Write-Host 'Connection Successful.' -ForegroundColor Green if ($Message) { Write-Output "Message: $Message" } } } catch { Write-Error "$($_.Exception.Message) - Line Number: $($_.InvocationInfo.ScriptLineNumber)" } } end {} } #EndRegion Watch-Connection
41.824561
243
0.627936
751e31d3630baf50285dc6492d2722a3d712448d
1,403
h
C
Source/Menu.h
AdriaSeSa/Minigame
ca2a0f2d47bba25341962b5229eb304159e91749
[ "MIT" ]
2
2021-03-16T00:49:11.000Z
2021-04-03T20:39:39.000Z
Source/Menu.h
AdriaSeSa/Minigame
ca2a0f2d47bba25341962b5229eb304159e91749
[ "MIT" ]
null
null
null
Source/Menu.h
AdriaSeSa/Minigame
ca2a0f2d47bba25341962b5229eb304159e91749
[ "MIT" ]
null
null
null
#pragma once #include "Display.h" #include "Game.h" class Menu { private: SDL_Surface* gameplayHud = IMG_Load("Assets/myAssets/Sprites/GameplayHUD.png"); SDL_Surface* coinHud = IMG_Load("Assets/myAssets/Sprites/Coin1.png"); SDL_Surface* playerlifeHud = IMG_Load("Assets/myAssets/Sprites/lifeHUD.png"); SDL_Surface* logoSurface = IMG_Load("Assets/myAssets/Sprites/logo.png"); SDL_Surface* teamLogoSurface = IMG_Load("Assets/myAssets/Sprites/TeamLogo.png"); SDL_Surface* textSurface; SDL_Surface* controlsSurface = IMG_Load("Assets/myAssets/Sprites/Controls.png"); SDL_Texture* menuTexture; SDL_Texture* playerlifeTexture; SDL_Texture* coinTexture; SDL_Texture* blackRcTexture; SDL_Texture* logoTexture; SDL_Texture* teamLogoTexture; SDL_Texture* text; SDL_Texture* controlsTexture; SDL_Rect textRect; SDL_Rect blackRc; SDL_Rect coinHudRc; SDL_Rect playerlifeHudRc; SDL_Rect menuRect; SDL_Rect logoRC; SDL_Rect teamLogoRC; SDL_Rect controlsRc; SDL_Rect gameOverCoinRc; public: Menu(); ~Menu(); void showText(SDL_Renderer* renderer, int x, int y, const char* message, TTF_Font* testFont, SDL_Color color); void gameplayHUD(SDL_Renderer* renderer); void menuHUD(SDL_Renderer* renderer); void initSurfaces(SDL_Renderer* renderer); void gameOverHUD(SDL_Renderer* renderer, SDL_Color color1, SDL_Color color2, TTF_Font* font, TTF_Font* font2); void freeMemory(); };
27.509804
111
0.783321
5b286146c5a9e0d0d26222b40b46b2eb91e32e88
11,566
lua
Lua
test/cases/0002-shell.lua
LuaDist-testing/lua-aplicado
78eb2b6e3fdd1ff26dbb7a4844fad0b80c55c5f6
[ "MIT" ]
4
2017-06-13T06:30:50.000Z
2020-08-01T22:01:07.000Z
test/cases/0002-shell.lua
LuaDist-testing/lua-aplicado
78eb2b6e3fdd1ff26dbb7a4844fad0b80c55c5f6
[ "MIT" ]
3
2017-07-24T21:43:49.000Z
2019-03-06T12:27:15.000Z
test/cases/0002-shell.lua
LuaDist-testing/lua-aplicado
78eb2b6e3fdd1ff26dbb7a4844fad0b80c55c5f6
[ "MIT" ]
7
2016-04-07T07:24:44.000Z
2017-08-30T12:24:12.000Z
-------------------------------------------------------------------------------- -- 0002-shell.lua: tests for shell piping -- This file is a part of Lua-Aplicado library -- Copyright (c) Lua-Aplicado authors (see file `COPYRIGHT` for the license) -------------------------------------------------------------------------------- local pairs = pairs local shell_read, shell_read_no_subst, shell_write, shell_write_no_subst, shell_write_async, shell_write_async_no_subst, shell_exec, shell_exec_no_subst, shell_escape, shell_escape_many, shell_escape_no_subst, shell_escape_many_no_subst, shell_format_command, shell_format_command_no_subst, shell_wait, exports = import 'lua-aplicado/shell.lua' { 'shell_read', 'shell_read_no_subst', 'shell_write', 'shell_write_no_subst', 'shell_write_async', 'shell_write_async_no_subst', 'shell_exec', 'shell_exec_no_subst', 'shell_escape', 'shell_escape_many', 'shell_escape_no_subst', 'shell_escape_many_no_subst', 'shell_format_command', 'shell_format_command_no_subst', 'shell_wait' } local ensure, ensure_equals, ensure_strequals, ensure_error, ensure_fails_with_substring = import 'lua-nucleo/ensure.lua' { 'ensure', 'ensure_equals', 'ensure_strequals', 'ensure_error', 'ensure_fails_with_substring' } local test = (...)("shell", exports) -------------------------------------------------------------------------------- test:test_for "shell_read" (function() ensure_strequals( "plain read", shell_read("/bin/echo", "foobar foo"), "foobar foo\n" ) ensure_equals("empty read", shell_read("/bin/true"), "") ensure_fails_with_substring( "false read", (function() shell_read("/bin/false") end), "command `/bin/false' stopped with rc==1" ) end) -------------------------------------------------------------------------------- -- This case tests only functionality that differs from shell_read test:test_for "shell_read_no_subst" (function() ensure_strequals( "plain read", shell_read_no_subst("/bin/echo", 'foobar foo'), 'foobar foo\n' ) end) -------------------------------------------------------------------------------- test:tests_for "shell_write" test:case "exit_0" (function () shell_write("exit 0\n", "/bin/sh") end) -- this test different from "exit 0" by miss newline after command test:case "closing_handle" (function () shell_write("exit 0", "/bin/sh") end) test:case "various_exit_codes" (function () for code = 1, 2 do ensure_fails_with_substring( "failed rc "..code, (function() shell_write("exit '" .. code .. "'\n", "/bin/sh") end), "command `/bin/sh' stopped with rc=="..code ) end end) -------------------------------------------------------------------------------- test:test_for "shell_exec" (function () ensure_equals("/bin/true", 0, shell_exec("/bin/true")) local rc = shell_exec("/bin/false") ensure("/bin/false", rc ~= 0) end) -------------------------------------------------------------------------------- -- TODO: generalize tests for shell_escape and shell_escape_no_subst after -- generalizing the functions -- GH#4 -- https://github.com/lua-aplicado/lua-aplicado/issues/4 test:tests_for "shell_escape" test:case "shell_escape_number" (function () ensure_strequals("shell_escape for a number", shell_escape(42), '42') end) test:case "shell_escape_empty_string" (function () ensure_strequals("shell_escape for an empty string", shell_escape(""), "''") end) test:case "shell_escape_special" (function () local special_sequences = { "&&"; "||"; "("; ")"; "{"; "}"; ">"; ">>"; "<"; "<<" } for _, v in pairs(special_sequences) do ensure_strequals("shell_escape for special sequences", shell_escape(v), v) end end) test:case "shell_escape_do_not_require_escaping" (function () ensure_strequals( "shell_escape for a solid string", shell_escape('solid_string'), 'solid_string' ) end) test:case "shell_escape_requires_escaping" (function () ensure_strequals("shell_escape for the space", shell_escape(' '), '" "') ensure_strequals( "shell_escape for a string with the space", shell_escape('a string with the space'), '"a string with the space"' ) ensure_strequals( "shell_escape for a string with the quote", shell_escape('a string with the "quote" inside'), '"a string with the \\"quote\\" inside"' ) end) -------------------------------------------------------------------------------- test:tests_for "shell_escape_no_subst" test:case "shell_escape_no_subst_number" (function () ensure_strequals( "shell_escape_no_subst for a number", shell_escape_no_subst(42), '42' ) end) test:case "shell_escape_no_subst_empty_string" (function () ensure_strequals( "shell_escape_no_subst for an empty string", shell_escape_no_subst(""), "''" ) end) test:case "shell_escape_no_subst_special" (function () local special_sequences = { "&&"; "||"; "("; ")"; "{"; "}"; ">"; ">>"; "<"; "<<" } for _, v in pairs(special_sequences) do ensure_strequals( "shell_escape_no_subst for special sequences", shell_escape_no_subst(v), v ) end end) test:case "shell_escape_no_subst_do_not_require_escaping" (function () ensure_strequals( "shell_escape_no_subst for a solid string", shell_escape_no_subst('solid_string'), 'solid_string' ) end) test:case "shell_escape_no_subst_requires_escaping" (function () ensure_strequals( "shell_escape_no_subst for the space", shell_escape_no_subst(" "), "' '" ) ensure_strequals( "shell_escape_no_subst for a string with the space", shell_escape_no_subst("a string with the space"), "'a string with the space'" ) ensure_strequals( "shell_escape_no_subst for a string with the single quote", shell_escape_no_subst("a string with the 'single quote' inside"), "'a string with the \\'single quote\\' inside'" ) end) -------------------------------------------------------------------------------- test:test_for "shell_escape_many" (function () local param_1 = 42 local param_2 = ">>" -- special sequence local param_3 = "solid_string" local param_4 = "a string with the space" local param_5 = 'a string with the "quote" inside' local param_6 = "" local res_1, res_2, res_3, res_4, res_5, res_6 = shell_escape_many(param_1, param_2, param_3, param_4, param_5, param_6) ensure_strequals( "shell_escape_many for a number", shell_escape(param_1), res_1 ) ensure_strequals( "shell_escape_many for special sequences", shell_escape(param_2), res_2 ) ensure_strequals( "shell_escape_many for a solid string", shell_escape(param_3), res_3 ) ensure_strequals( "shell_escape_many for a string with the space", shell_escape(param_4), res_4 ) ensure_strequals( "shell_escape_many for a string with the quote", shell_escape(param_5), res_5 ) ensure_strequals( "shell_escape_many an empty string", shell_escape(param_6), res_6 ) end) -------------------------------------------------------------------------------- test:test_for "shell_escape_many_no_subst" (function () local param_1 = 42 local param_2 = ">>" -- special sequence local param_3 = "solid_string" local param_4 = "a string with the space" local param_5 = "a string with the 'single quote' inside" local param_6 = "" local res_1, res_2, res_3, res_4, res_5, res_6 = shell_escape_many_no_subst( param_1, param_2, param_3, param_4, param_5, param_6 ) ensure_strequals( "shell_escape_many for a number", shell_escape_no_subst(param_1), res_1 ) ensure_strequals( "shell_escape_many for special sequences", shell_escape_no_subst(param_2), res_2 ) ensure_strequals( "shell_escape_many for a solid string", shell_escape_no_subst(param_3), res_3 ) ensure_strequals( "shell_escape_many for a string with the space", shell_escape_no_subst(param_4), res_4 ) ensure_strequals( "shell_escape_many for a string with the quote", shell_escape_no_subst(param_5), res_5 ) ensure_strequals( "shell_escape_many an empty string", shell_escape_no_subst(param_6), res_6 ) end) -------------------------------------------------------------------------------- test:test_for "shell_format_command" (function () local param_1 = 42 local param_2 = ">>" local param_3 = "solid_string" local param_4 = "a string with the space" local param_5 = 'a string with the "quote" inside' local param_6 = "" local expected = "42" .. " " .. ">>" .. " " .. "solid_string" .. " " .. '"a string with the space"' .. " " .. '"a string with the \\"quote\\" inside"' .. " " .. "''" ensure_strequals( "shell_format_command", shell_format_command(param_1, param_2, param_3, param_4, param_5, param_6), expected ) end) -------------------------------------------------------------------------------- test:test_for "shell_format_command_no_subst" (function () local param_1 = 42 local param_2 = ">>" local param_3 = "solid_string" local param_4 = "a string with the space" local param_5 = "a string with the 'single quote' inside" local param_6 = "" local expected = "42" .. " " .. ">>" .. " " .. "solid_string" .. " " .. "'a string with the space'" .. " " .. "'a string with the \\'single quote\\' inside'" .. " " .. "''" ensure_strequals( "shell_format_command", shell_format_command_no_subst( param_1, param_2, param_3, param_4, param_5, param_6 ), expected ) end) test:test_for "shell_write_async" -- Based on real bug scenario: https://redmine-tmp.iphonestudio.ru/issues/1564 -- shell_write_async functionality mostly covered by shell_write tests test:case "async_write_exit_0" (function() local pid = shell_write_async("exit 0\n", "/bin/sh") shell_wait(pid, "/bin/sh") end) test:test_for "shell_write_async_no_subst" -- Based on real bug scenario: https://redmine-tmp.iphonestudio.ru/issues/1564 -- shell_write_async_no_subst functionality mostly covered by shell_write tests test:case "async_write_no_subst_exit_0" (function() local pid = shell_write_async_no_subst("exit 0\n", "/bin/sh") shell_wait(pid, "/bin/sh") end) test:test_for "shell_write_no_subst" -- Based on real bug scenario: https://redmine-tmp.iphonestudio.ru/issues/1564 -- shell_write_no_subst functionality mostly covered by shell_write tests test:case "shell_write_no_subst_exit_0" (function() shell_write_no_subst("exit 0\n", "/bin/sh") end) -------------------------------------------------------------------------------- -- shell_wait is covered by tests shell_read and shell_write test:UNTESTED "shell_wait" -- shell_exec_no_subst is covered by shell_exec test:UNTESTED "shell_exec_no_subst"
27.150235
81
0.593377
19cb1c56dcbb87e284569a000903128967c4cfcf
2,258
swift
Swift
Bigu/Bill.swift
bschron/Bigu
605301ce41cfbab7a465fa46fefabe0150a47135
[ "MIT" ]
1
2018-06-11T06:34:17.000Z
2018-06-11T06:34:17.000Z
Bigu/Bill.swift
bschron/Bigu
605301ce41cfbab7a465fa46fefabe0150a47135
[ "MIT" ]
null
null
null
Bigu/Bill.swift
bschron/Bigu
605301ce41cfbab7a465fa46fefabe0150a47135
[ "MIT" ]
null
null
null
// // Bill.swift // Bigu // // Created by Bruno Chroniaris on 4/18/15. // Copyright (c) 2015 Universidade Federal De Alagoas. All rights reserved. // import Foundation import BrightFutures public class Bill { // MARK: -Properties private var _bill: Float? = nil public private(set) var bill: Float { get { return self._bill != nil ? self._bill! : 0 } set { self._bill = newValue } } private(set) var handler: BillingHandlerDelegate? public init() {} public init(fromBillValue value: Float) { self.bill = value } // MARK: -Methods public func charge (chargingValue value: Float) { self.bill -= value self.handler?.updateBillingUI() } public func pay (payingValue value: Float) { self.bill += value self.handler?.updateBillingUI() } public func registerAsHandler (handler: BillingHandlerDelegate) { self.handler = handler self.handler?.updateBillingUI() } public func clearRegisteredHandler() { self.handler = nil } // MARK: -Class Properties and Methods private struct wrap { static var firstRun: Bool = true static var tax: Float? = Bill.loadTaxValue() { didSet { if !Bill.wrap.firstRun { Bill.saveTaxValue() } Bill.wrap.firstRun = false } } } class public var taxValue: Float { get { return Bill.wrap.tax != nil ? Bill.wrap.tax! : 0 } set { if newValue <= 0 { Bill.wrap.tax = nil } else { Bill.wrap.tax = newValue } } } class private func saveTaxValue() { Queue.global.async({ let defaults = NSUserDefaults.standardUserDefaults() defaults.setObject(Bill.wrap.tax, forKey: "BillTaxValueKey") defaults.synchronize() }) } class private func loadTaxValue() -> Float? { let defaults = NSUserDefaults.standardUserDefaults() return defaults.objectForKey("BillTaxValueKey") as? Float } }
25.659091
76
0.547387
4a5107884b8d56aad51a58711cbfb3154e9341d4
6,582
js
JavaScript
routes/crud.js
eroc218/allcountjs
695f873c0ac0fe39be5e0a89952750d7453133f6
[ "MIT" ]
493
2015-01-08T12:54:55.000Z
2021-12-06T15:10:41.000Z
routes/crud.js
Sugson/allcountjs
695f873c0ac0fe39be5e0a89952750d7453133f6
[ "MIT" ]
142
2015-01-08T11:57:25.000Z
2020-02-10T11:57:41.000Z
routes/crud.js
Sugson/allcountjs
695f873c0ac0fe39be5e0a89952750d7453133f6
[ "MIT" ]
125
2015-02-23T00:00:29.000Z
2021-09-08T09:27:31.000Z
var _ = require('underscore'); var Q = require('q'); var moment = require('moment'); module.exports = function (crudService, referenceService, entityDescriptionService, storageDriver, injection, routeUtil, cloudinaryService, securityService) { var route = {}; var extractEntityCrudId = routeUtil.extractEntityCrudId; route.checkReadPermissionMiddleware = function (req, res, next) { var entityCrudId = extractEntityCrudId(req); if (entityCrudId && !entityDescriptionService.userHasReadAccess(entityCrudId, req.user)) { res.send(403, 'Permission denied'); } else { next(); } }; /** * @deprecated * @param req * @param res * @param next */ route.checkWritePermissionMiddleware = function (req, res, next) { var entityCrudId = extractEntityCrudId(req); if (entityCrudId && !entityDescriptionService.userHasWriteAccess(entityCrudId, req.user)) { res.send(403, 'Permission denied'); } else { next(); } }; function filteringAndSorting(req) { var filtering = req.query.filtering && JSON.parse(req.query.filtering) || {}; return { textSearch: filtering.textSearch, filtering: filtering.filtering, sorting: filtering.sorting }; } route.findCount = function (req, res) { var strategyForCrudId = crudService.strategyForCrudId(extractEntityCrudId(req)); var filtering = filteringAndSorting(req); Q.all([ strategyForCrudId.findCount(filtering), strategyForCrudId.getTotalRow(filtering) ]).spread(function (count, totalRow) { res.json({ count: count, totalRow: totalRow || undefined }); }).done(); }; route.findRange = function (req, res) { var entityCrudId = extractEntityCrudId(req); var allFields = entityDescriptionService.entityDescription(entityCrudId).allFields; crudService .strategyForCrudId(entityCrudId) .findRange(filteringAndSorting(req), req.query.start, req.query.count) .then(function (result) { res.json(result.map(function (i) { return route.formatJsonObj(i, allFields) })); }) .done(); }; function removeReadOnlyFieldValues (entityCrudId, entity) { _.forEach(entityDescriptionService.entityDescription(entityCrudId).allFields, function (field, fieldName) { if (field.readOnly()) { delete entity[fieldName]; } }); return entity; } route.createEntity = function (req, res) { var entityCrudId = extractEntityCrudId(req); var entity = removeReadOnlyFieldValues(entityCrudId, req.body); crudService.strategyForCrudId(entityCrudId).createEntity(entity).then(function (result) { res.send(result.toString()); }).done(); }; route.readEntity = function (req, res) { var entityCrudId = extractEntityCrudId(req); crudService .strategyForCrudId(entityCrudId) .readEntity(req.params.entityId) .then(function (result) { res.json(route.formatJsonObj(result, entityDescriptionService.entityDescription(entityCrudId).allFields)); }) .done(); }; route.updateEntity = function (req, res) { var entityCrudId = extractEntityCrudId(req); var entity = removeReadOnlyFieldValues(entityCrudId, req.body); crudService.strategyForCrudId(entityCrudId).updateEntity(entity).then(function (result) { res.json(route.formatJsonObj(result, entityDescriptionService.entityDescription(entityCrudId).allFields)); }).done(); }; route.deleteEntity = function (req, res) { var entityCrudId = extractEntityCrudId(req); crudService .strategyForCrudId(entityCrudId) .deleteEntity(req.params.entityId) .then(function (result) { res.json(route.formatJsonObj(result, entityDescriptionService.entityDescription(entityCrudId).allFields)); }) .done(); }; route.formatJsonObj = function (entity, fields) { _.forEach(entity, function (value, property) { if (_.isDate(value)) { entity[property] = moment(value).format(fields[property].fieldType.hasTime ? 'YYYY-MM-DD HH:mm:ss' : 'YYYY-MM-DD'); } }); return entity; }; route.referenceValues = function (req, res) { //TODO support reference TOP values referenceService.referenceValues({entityTypeId: req.params.entityTypeId}, req.query.query).then(function (result) { res.json(result); }); }; route.referenceValueByEntityId = function (req, res) { referenceService.referenceValueByEntityId(entityDescriptionService.entityTypeIdCrudId(req.params.entityTypeId), req.params.entityId).then(function (result) { res.json(result); }); }; route.uploadFile = function (req, res) { req.pipe(req.busboy); req.busboy.on('file', function (fieldname, file, filename) { var uploadPromise; if (req.params.provider === 'cloudinary') { uploadPromise = cloudinaryService.upload(file, filename); } else { uploadPromise = storageDriver.createFile(filename, file).then(function (fileId) { return {fileId: fileId, name: filename} }); } uploadPromise.then(function (result) { res.json({files: [result]}); }).done(); }); }; var mimeTypes = { pdf: 'application/pdf' }; route.downloadFile = function (req, res) { storageDriver.getFile(req.params.fileId).then(function (file) { var split = file.fileName.split('.'); var extension = ''; if (split.length > 1) { extension = split[split.length - 1]; } res.set('Content-Type', mimeTypes[extension] || 'application/octet-stream'); if (!mimeTypes[extension]) { res.set('Content-Disposition', 'attachment; filename="' + file.fileName + '"'); } file.stream.pipe(res); }).done(); }; route.withUserScope = function (req, res, next) { return securityService.withUserScope(req.user, next); }; return route; };
37.397727
165
0.602856
42fde0d43fa0982b92d2179b5114aaf0f181a30b
105
dart
Dart
packages/digital_currency/test/src/external/response/response_api.dart
juanmajh96/prueba_tecnica_tekus
a89ffbf2c5ac08ed89a81b877b99c2904c6fabb3
[ "MIT" ]
null
null
null
packages/digital_currency/test/src/external/response/response_api.dart
juanmajh96/prueba_tecnica_tekus
a89ffbf2c5ac08ed89a81b877b99c2904c6fabb3
[ "MIT" ]
null
null
null
packages/digital_currency/test/src/external/response/response_api.dart
juanmajh96/prueba_tecnica_tekus
a89ffbf2c5ac08ed89a81b877b99c2904c6fabb3
[ "MIT" ]
null
null
null
const responseApi = '''{"data": {"base": "BTC","currency": "COP","amount": "180475552.0814525"}}''';
35
84
0.571429
3e531d1a5ba3c1ee6fc256667d189579afeaa4f4
2,853
dart
Dart
lib/review.dart
Yenniferh/Platzi-Trips
e52dd5458fea0bd771a6172601fae77fbe1d4be7
[ "MIT" ]
null
null
null
lib/review.dart
Yenniferh/Platzi-Trips
e52dd5458fea0bd771a6172601fae77fbe1d4be7
[ "MIT" ]
null
null
null
lib/review.dart
Yenniferh/Platzi-Trips
e52dd5458fea0bd771a6172601fae77fbe1d4be7
[ "MIT" ]
null
null
null
import 'package:flutter/material.dart'; import 'package:platzi_trips/review_list.dart'; class Review extends StatelessWidget { String pathImg = 'assets/img/review_photo.jpg'; String name; int punctuation; int reviews; String comment; int photos; Review(this.pathImg, this.name, this.reviews, this.photos, this.punctuation, this.comment); @override Widget build(BuildContext context) { final stars = Container( margin: EdgeInsets.only(left: 10.0), child: Row( mainAxisSize: MainAxisSize.min, children: <Widget>[ Icon(Icons.star, size: 15.0 ,color: Color(0xfff2c611)), Icon(Icons.star, size: 15.0 ,color: Color(0xfff2c611)), Icon(Icons.star, size: 15.0 ,color: Color(0xfff2c611)), Icon(Icons.star, size: 15.0 ,color: Color(0xfff2c611)), Icon(Icons.star, size: 15.0 ,color: Color(0xfff2c611)), ], ) ); final userComment = Container( margin: EdgeInsets.only( left: 20.0, right: 20.0, ), child: Text( comment, style: TextStyle( fontFamily: 'Lato', fontSize: 14.0, fontWeight: FontWeight.w900, ), ), ); final userInfo= Container( margin: EdgeInsets.only( left: 20.0, right: 20.0, ), child: Row( children: <Widget>[ Text( reviews.toString() + ' review · ' + photos.toString() + ' photos', style: TextStyle( fontFamily: 'Lato', fontSize: 13.0, color: Color(0xFFa3a5a7), ), ), stars ], ) ); final userName = Container( margin: EdgeInsets.only( left: 20.0, right: 20.0, ), child: Text( name, style: TextStyle( fontFamily: 'Lato', fontSize: 18.0, ), ), ); final userDetails = Flexible( child: Container( child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: <Widget>[ userName, userInfo, userComment, ], ), ), ); final photo = Container( margin: EdgeInsets.only( top: 5.0, left: 20.0, ), width: 80.0, height: 80.0, decoration: BoxDecoration( shape: BoxShape.circle, image: DecorationImage(image: AssetImage(pathImg), fit: BoxFit.cover) ), ); // TODO: Correct the image positioning return Container( margin: EdgeInsets.only(bottom: 10.0), child: Row( crossAxisAlignment: CrossAxisAlignment.start, children: <Widget>[ photo, userDetails, ], ), ); } }
23.578512
93
0.521907