Skip to content

Commit 070b88d

Browse files
author
osimloeff
committed
Upgrade to 2018
1 parent 57300d9 commit 070b88d

File tree

183 files changed

+5271
-2191
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

183 files changed

+5271
-2191
lines changed

.gitattributes

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
###############################################################################
2+
# Set default behavior to automatically normalize line endings.
3+
###############################################################################
4+
* text=auto
5+
6+
###############################################################################
7+
# Set default behavior for command prompt diff.
8+
#
9+
# This is need for earlier builds of msysgit that does not have it on by
10+
# default for csharp files.
11+
# Note: This is only used by command line
12+
###############################################################################
13+
#*.cs diff=csharp
14+
15+
###############################################################################
16+
# Set the merge driver for project and solution files
17+
#
18+
# Merging from the command prompt will add diff markers to the files if there
19+
# are conflicts (Merging from VS is not affected by the settings below, in VS
20+
# the diff markers are never inserted). Diff markers may cause the following
21+
# file extensions to fail to load in VS. An alternative would be to treat
22+
# these files as binary and thus will always conflict and require user
23+
# intervention with every merge. To do so, just uncomment the entries below
24+
###############################################################################
25+
#*.sln merge=binary
26+
#*.csproj merge=binary
27+
#*.vbproj merge=binary
28+
#*.vcxproj merge=binary
29+
#*.vcproj merge=binary
30+
#*.dbproj merge=binary
31+
#*.fsproj merge=binary
32+
#*.lsproj merge=binary
33+
#*.wixproj merge=binary
34+
#*.modelproj merge=binary
35+
#*.sqlproj merge=binary
36+
#*.wwaproj merge=binary
37+
38+
###############################################################################
39+
# behavior for image files
40+
#
41+
# image files are treated as binary by default.
42+
###############################################################################
43+
#*.jpg binary
44+
#*.png binary
45+
#*.gif binary
46+
47+
###############################################################################
48+
# diff behavior for common document formats
49+
#
50+
# Convert binary document formats to text before diffing them. This feature
51+
# is only available from the command line. Turn it on by uncommenting the
52+
# entries below.
53+
###############################################################################
54+
#*.doc diff=astextplain
55+
#*.DOC diff=astextplain
56+
#*.docx diff=astextplain
57+
#*.DOCX diff=astextplain
58+
#*.dot diff=astextplain
59+
#*.DOT diff=astextplain
60+
#*.pdf diff=astextplain
61+
#*.PDF diff=astextplain
62+
#*.rtf diff=astextplain
63+
#*.RTF diff=astextplain

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@
22
.Rhistory
33
.RData
44
.Ruserdata
5+
.vs/

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Package: piwebapi
22
Type: Package
33
Title: PI Web API client R package
4-
Version: 1.1.1
4+
Version: 1.11.0
55
Author: Marcos Vainer Loeff
66
Maintainer: OSIsoft PI Developers Club <[email protected]>
77
Description: This is an R package generated using the PI Web API JSON Swagger specification.

R/PIAmbiguous.r

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
PIAmbiguous <- function(reason = NULL) {
2+
if (is.null(reason) == FALSE) {
3+
if (is.character(reason) == FALSE) {
4+
return (print(paste0("Error: reason must be a string.")))
5+
}
6+
}
7+
value <- list(
8+
Reason = reason)
9+
valueCleaned <- rmNullObs(value)
10+
attr(valueCleaned, "className") <- "PIAmbiguous"
11+
return(valueCleaned)
12+
}

R/PIAnnotationLinks.r

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
PIAnnotationLinks <- function(self = NULL, owner = NULL) {
1+
PIAnnotationLinks <- function(self = NULL, owner = NULL, mediaData = NULL, mediaMetadata = NULL) {
22
if (is.null(self) == FALSE) {
33
if (is.character(self) == FALSE) {
44
return (print(paste0("Error: self must be a string.")))
@@ -9,9 +9,21 @@ PIAnnotationLinks <- function(self = NULL, owner = NULL) {
99
return (print(paste0("Error: owner must be a string.")))
1010
}
1111
}
12+
if (is.null(mediaData) == FALSE) {
13+
if (is.character(mediaData) == FALSE) {
14+
return (print(paste0("Error: mediaData must be a string.")))
15+
}
16+
}
17+
if (is.null(mediaMetadata) == FALSE) {
18+
if (is.character(mediaMetadata) == FALSE) {
19+
return (print(paste0("Error: mediaMetadata must be a string.")))
20+
}
21+
}
1222
value <- list(
1323
Self = self,
14-
Owner = owner)
24+
Owner = owner,
25+
MediaData = mediaData,
26+
MediaMetadata = mediaMetadata)
1527
valueCleaned <- rmNullObs(value)
1628
attr(valueCleaned, "className") <- "PIAnnotationLinks"
1729
return(valueCleaned)

R/PIAssetServer.r

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
PIAssetServer <- function(webId = NULL, id = NULL, name = NULL, description = NULL, path = NULL, isConnected = NULL, serverVersion = NULL, extendedProperties = NULL, links = NULL, webException = NULL) {
1+
PIAssetServer <- function(webId = NULL, id = NULL, name = NULL, description = NULL, path = NULL, isConnected = NULL, serverVersion = NULL, serverTime = NULL, extendedProperties = NULL, links = NULL, webException = NULL) {
22
if (is.null(webId) == FALSE) {
33
if (is.character(webId) == FALSE) {
44
return (print(paste0("Error: webId must be a string.")))
@@ -34,6 +34,11 @@ PIAssetServer <- function(webId = NULL, id = NULL, name = NULL, description = NU
3434
return (print(paste0("Error: serverVersion must be a string.")))
3535
}
3636
}
37+
if (is.null(serverTime) == FALSE) {
38+
if (is.character(serverTime) == FALSE) {
39+
return (print(paste0("Error: serverTime must be a string.")))
40+
}
41+
}
3742
if (is.null(extendedProperties) == FALSE) {
3843
}
3944
if (is.null(links) == FALSE) {
@@ -56,6 +61,7 @@ PIAssetServer <- function(webId = NULL, id = NULL, name = NULL, description = NU
5661
Path = path,
5762
IsConnected = isConnected,
5863
ServerVersion = serverVersion,
64+
ServerTime = serverTime,
5965
ExtendedProperties = extendedProperties,
6066
Links = links,
6167
WebException = webException)

R/PIAssetServerLinks.r

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
PIAssetServerLinks <- function(self = NULL, databases = NULL, securityIdentities = NULL, securityMappings = NULL, unitClasses = NULL, analysisRulePlugIns = NULL, timeRulePlugIns = NULL, security = NULL, securityEntries = NULL) {
1+
PIAssetServerLinks <- function(self = NULL, databases = NULL, notificationContactTemplates = NULL, securityIdentities = NULL, securityMappings = NULL, unitClasses = NULL, analysisRulePlugIns = NULL, timeRulePlugIns = NULL, security = NULL, securityEntries = NULL) {
22
if (is.null(self) == FALSE) {
33
if (is.character(self) == FALSE) {
44
return (print(paste0("Error: self must be a string.")))
@@ -9,6 +9,11 @@ PIAssetServerLinks <- function(self = NULL, databases = NULL, securityIdentities
99
return (print(paste0("Error: databases must be a string.")))
1010
}
1111
}
12+
if (is.null(notificationContactTemplates) == FALSE) {
13+
if (is.character(notificationContactTemplates) == FALSE) {
14+
return (print(paste0("Error: notificationContactTemplates must be a string.")))
15+
}
16+
}
1217
if (is.null(securityIdentities) == FALSE) {
1318
if (is.character(securityIdentities) == FALSE) {
1419
return (print(paste0("Error: securityIdentities must be a string.")))
@@ -47,6 +52,7 @@ PIAssetServerLinks <- function(self = NULL, databases = NULL, securityIdentities
4752
value <- list(
4853
Self = self,
4954
Databases = databases,
55+
NotificationContactTemplates = notificationContactTemplates,
5056
SecurityIdentities = securityIdentities,
5157
SecurityMappings = securityMappings,
5258
UnitClasses = unitClasses,

R/PIAttribute.r

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
PIAttribute <- function(webId = NULL, id = NULL, name = NULL, description = NULL, path = NULL, type = NULL, typeQualifier = NULL, defaultUnitsName = NULL, dataReferencePlugIn = NULL, configString = NULL, isConfigurationItem = NULL, isExcluded = NULL, isHidden = NULL, isManualDataEntry = NULL, hasChildren = NULL, categoryNames = NULL, step = NULL, traitName = NULL, links = NULL, webException = NULL) {
1+
PIAttribute <- function(webId = NULL, id = NULL, name = NULL, description = NULL, path = NULL, type = NULL, typeQualifier = NULL, defaultUnitsName = NULL, displayDigits = NULL, dataReferencePlugIn = NULL, configString = NULL, isConfigurationItem = NULL, isExcluded = NULL, isHidden = NULL, isManualDataEntry = NULL, hasChildren = NULL, categoryNames = NULL, step = NULL, traitName = NULL, defaultUnitsNameAbbreviation = NULL, span = NULL, zero = NULL, links = NULL, webException = NULL) {
22
if (is.null(webId) == FALSE) {
33
if (is.character(webId) == FALSE) {
44
return (print(paste0("Error: webId must be a string.")))
@@ -39,6 +39,11 @@ PIAttribute <- function(webId = NULL, id = NULL, name = NULL, description = NULL
3939
return (print(paste0("Error: defaultUnitsName must be a string.")))
4040
}
4141
}
42+
if (is.null(displayDigits) == FALSE) {
43+
if (check.integer(displayDigits) == FALSE) {
44+
return (print(paste0("Error: displayDigits must be an integer.")))
45+
}
46+
}
4247
if (is.null(dataReferencePlugIn) == FALSE) {
4348
if (is.character(dataReferencePlugIn) == FALSE) {
4449
return (print(paste0("Error: dataReferencePlugIn must be a string.")))
@@ -92,6 +97,15 @@ PIAttribute <- function(webId = NULL, id = NULL, name = NULL, description = NULL
9297
return (print(paste0("Error: traitName must be a string.")))
9398
}
9499
}
100+
if (is.null(defaultUnitsNameAbbreviation) == FALSE) {
101+
if (is.character(defaultUnitsNameAbbreviation) == FALSE) {
102+
return (print(paste0("Error: defaultUnitsNameAbbreviation must be a string.")))
103+
}
104+
}
105+
if (is.null(span) == FALSE) {
106+
}
107+
if (is.null(zero) == FALSE) {
108+
}
95109
if (is.null(links) == FALSE) {
96110
className <- attr(links, "className")
97111
if ((is.null(className)) || (className != "PIAttributeLinks")) {
@@ -113,6 +127,7 @@ PIAttribute <- function(webId = NULL, id = NULL, name = NULL, description = NULL
113127
Type = type,
114128
TypeQualifier = typeQualifier,
115129
DefaultUnitsName = defaultUnitsName,
130+
DisplayDigits = displayDigits,
116131
DataReferencePlugIn = dataReferencePlugIn,
117132
ConfigString = configString,
118133
IsConfigurationItem = isConfigurationItem,
@@ -123,6 +138,9 @@ PIAttribute <- function(webId = NULL, id = NULL, name = NULL, description = NULL
123138
CategoryNames = categoryNames,
124139
Step = step,
125140
TraitName = traitName,
141+
DefaultUnitsNameAbbreviation = defaultUnitsNameAbbreviation,
142+
Span = span,
143+
Zero = zero,
126144
Links = links,
127145
WebException = webException)
128146
valueCleaned <- rmNullObs(value)

R/PIAttributeTemplate.r

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
PIAttributeTemplate <- function(webId = NULL, id = NULL, name = NULL, description = NULL, path = NULL, type = NULL, typeQualifier = NULL, defaultUnitsName = NULL, defaultValue = NULL, dataReferencePlugIn = NULL, configString = NULL, isConfigurationItem = NULL, isExcluded = NULL, isHidden = NULL, isManualDataEntry = NULL, hasChildren = NULL, categoryNames = NULL, traitName = NULL, links = NULL, webException = NULL) {
1+
PIAttributeTemplate <- function(webId = NULL, id = NULL, name = NULL, description = NULL, path = NULL, type = NULL, typeQualifier = NULL, defaultUnitsName = NULL, defaultValue = NULL, dataReferencePlugIn = NULL, configString = NULL, isConfigurationItem = NULL, isExcluded = NULL, isHidden = NULL, isManualDataEntry = NULL, hasChildren = NULL, categoryNames = NULL, traitName = NULL, defaultUnitsNameAbbreviation = NULL, links = NULL, webException = NULL) {
22
if (is.null(webId) == FALSE) {
33
if (is.character(webId) == FALSE) {
44
return (print(paste0("Error: webId must be a string.")))
@@ -89,6 +89,11 @@ PIAttributeTemplate <- function(webId = NULL, id = NULL, name = NULL, descriptio
8989
return (print(paste0("Error: traitName must be a string.")))
9090
}
9191
}
92+
if (is.null(defaultUnitsNameAbbreviation) == FALSE) {
93+
if (is.character(defaultUnitsNameAbbreviation) == FALSE) {
94+
return (print(paste0("Error: defaultUnitsNameAbbreviation must be a string.")))
95+
}
96+
}
9297
if (is.null(links) == FALSE) {
9398
className <- attr(links, "className")
9499
if ((is.null(className)) || (className != "PIAttributeTemplateLinks")) {
@@ -120,6 +125,7 @@ PIAttributeTemplate <- function(webId = NULL, id = NULL, name = NULL, descriptio
120125
HasChildren = hasChildren,
121126
CategoryNames = categoryNames,
122127
TraitName = traitName,
128+
DefaultUnitsNameAbbreviation = defaultUnitsNameAbbreviation,
123129
Links = links,
124130
WebException = webException)
125131
valueCleaned <- rmNullObs(value)

R/PIDataPipeEvent.r

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
PIDataPipeEvent <- function(action = NULL, timestamp = NULL, unitsAbbreviation = NULL, good = NULL, questionable = NULL, substituted = NULL, annotated = NULL, value = NULL, errors = NULL, webException = NULL) {
2+
if (is.null(action) == FALSE) {
3+
if (is.character(action) == FALSE) {
4+
return (print(paste0("Error: action must be a string.")))
5+
}
6+
}
7+
if (is.null(timestamp) == FALSE) {
8+
if (is.character(timestamp) == FALSE) {
9+
return (print(paste0("Error: timestamp must be a string.")))
10+
}
11+
}
12+
if (is.null(unitsAbbreviation) == FALSE) {
13+
if (is.character(unitsAbbreviation) == FALSE) {
14+
return (print(paste0("Error: unitsAbbreviation must be a string.")))
15+
}
16+
}
17+
if (is.null(good) == FALSE) {
18+
if (is.logical(good) == FALSE) {
19+
return (print(paste0("Error: good must be a boolean.")))
20+
}
21+
}
22+
if (is.null(questionable) == FALSE) {
23+
if (is.logical(questionable) == FALSE) {
24+
return (print(paste0("Error: questionable must be a boolean.")))
25+
}
26+
}
27+
if (is.null(substituted) == FALSE) {
28+
if (is.logical(substituted) == FALSE) {
29+
return (print(paste0("Error: substituted must be a boolean.")))
30+
}
31+
}
32+
if (is.null(annotated) == FALSE) {
33+
if (is.logical(annotated) == FALSE) {
34+
return (print(paste0("Error: annotated must be a boolean.")))
35+
}
36+
}
37+
if (is.null(value) == FALSE) {
38+
}
39+
if (is.null(errors) == FALSE) {
40+
if (is.vector(errors) == FALSE) {
41+
return (print(paste0("Error: errors must be a vector.")))
42+
}
43+
}
44+
if (is.null(webException) == FALSE) {
45+
className <- attr(webException, "className")
46+
if ((is.null(className)) || (className != "PIWebException")) {
47+
return (print(paste0("Error: the class from the parameter webException should be PIWebException.")))
48+
}
49+
}
50+
value <- list(
51+
Action = action,
52+
Timestamp = timestamp,
53+
UnitsAbbreviation = unitsAbbreviation,
54+
Good = good,
55+
Questionable = questionable,
56+
Substituted = substituted,
57+
Annotated = annotated,
58+
Value = value,
59+
Errors = errors,
60+
WebException = webException)
61+
valueCleaned <- rmNullObs(value)
62+
attr(valueCleaned, "className") <- "PIDataPipeEvent"
63+
return(valueCleaned)
64+
}

0 commit comments

Comments
 (0)