Compare commits
No commits in common. "master" and "feature/media-col" have entirely different histories.
master
...
feature/me
|
@ -1,5 +1,2 @@
|
|||
idea
|
||||
cmd
|
||||
vendor
|
||||
.vim
|
||||
.vscode
|
||||
cmd
|
|
@ -1,20 +1,3 @@
|
|||
/*
|
||||
** Copyright 2022 Dolysis Consulting Limited
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** For changes see the git log
|
||||
*/
|
||||
package ipp
|
||||
|
||||
import (
|
||||
|
|
|
@ -1,20 +1,3 @@
|
|||
/*
|
||||
** Copyright 2022 Dolysis Consulting Limited
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** For changes see the git log
|
||||
*/
|
||||
package ipp
|
||||
|
||||
import (
|
||||
|
@ -58,8 +41,8 @@ func NewSocketAdapter(host string, useTLS bool) *SocketAdapter {
|
|||
}
|
||||
}
|
||||
|
||||
// DoRequest performs the given IPP request to the given URL, returning the IPP response or an error if one occurred.
|
||||
// Additional data will be written to an io.Writer if additionalData is not nil
|
||||
//DoRequest performs the given IPP request to the given URL, returning the IPP response or an error if one occurred.
|
||||
//Additional data will be written to an io.Writer if additionalData is not nil
|
||||
func (h *SocketAdapter) SendRequest(url string, r *Request, additionalData io.Writer) (*Response, error) {
|
||||
for i := 0; i < h.RequestRetryLimit; i++ {
|
||||
// encode request
|
||||
|
@ -149,7 +132,7 @@ func (h *SocketAdapter) SendRequest(url string, r *Request, additionalData io.Wr
|
|||
return nil, errors.New("request retry limit exceeded")
|
||||
}
|
||||
|
||||
// GetSocket returns the path to the cupsd socket by searching SocketSearchPaths
|
||||
//GetSocket returns the path to the cupsd socket by searching SocketSearchPaths
|
||||
func (h *SocketAdapter) GetSocket() (string, error) {
|
||||
for _, path := range h.SocketSearchPaths {
|
||||
fi, err := os.Stat(path)
|
||||
|
@ -170,7 +153,7 @@ func (h *SocketAdapter) GetSocket() (string, error) {
|
|||
return "", SocketNotFoundError
|
||||
}
|
||||
|
||||
// GetCert returns the current CUPs authentication certificate by searching CertSearchPaths
|
||||
//GetCert returns the current CUPs authentication certificate by searching CertSearchPaths
|
||||
func (h *SocketAdapter) GetCert() (string, error) {
|
||||
for _, path := range h.CertSearchPaths {
|
||||
f, err := os.Open(path)
|
||||
|
|
17
adapter.go
17
adapter.go
|
@ -1,20 +1,3 @@
|
|||
/*
|
||||
** Copyright 2022 Dolysis Consulting Limited
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** For changes see the git log
|
||||
*/
|
||||
package ipp
|
||||
|
||||
import "io"
|
||||
|
|
17
attribute.go
17
attribute.go
|
@ -1,20 +1,3 @@
|
|||
/*
|
||||
** Copyright 2022 Dolysis Consulting Limited
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** For changes see the git log
|
||||
*/
|
||||
package ipp
|
||||
|
||||
import (
|
||||
|
|
|
@ -1,20 +1,3 @@
|
|||
/*
|
||||
** Copyright 2022 Dolysis Consulting Limited
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** For changes see the git log
|
||||
*/
|
||||
package ipp
|
||||
|
||||
import (
|
||||
|
|
17
constants.go
17
constants.go
|
@ -1,20 +1,3 @@
|
|||
/*
|
||||
** Copyright 2022 Dolysis Consulting Limited
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** For changes see the git log
|
||||
*/
|
||||
package ipp
|
||||
|
||||
// ipp status codes
|
||||
|
|
|
@ -1,20 +1,3 @@
|
|||
/*
|
||||
** Copyright 2022 Dolysis Consulting Limited
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** For changes see the git log
|
||||
*/
|
||||
package ipp
|
||||
|
||||
import (
|
||||
|
|
17
error.go
17
error.go
|
@ -1,20 +1,3 @@
|
|||
/*
|
||||
** Copyright 2022 Dolysis Consulting Limited
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** For changes see the git log
|
||||
*/
|
||||
package ipp
|
||||
|
||||
import "fmt"
|
||||
|
|
4
go.mod
4
go.mod
|
@ -1,3 +1,3 @@
|
|||
module git.st8l.com/dolysis/go-ipp
|
||||
module github.com/phin1x/go-ipp
|
||||
|
||||
go 1.19
|
||||
go 1.13
|
||||
|
|
|
@ -1,20 +1,3 @@
|
|||
/*
|
||||
** Copyright 2022 Dolysis Consulting Limited
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** For changes see the git log
|
||||
*/
|
||||
package ipp
|
||||
|
||||
import (
|
||||
|
|
17
request.go
17
request.go
|
@ -1,20 +1,3 @@
|
|||
/*
|
||||
** Copyright 2022 Dolysis Consulting Limited
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** For changes see the git log
|
||||
*/
|
||||
package ipp
|
||||
|
||||
import (
|
||||
|
|
17
response.go
17
response.go
|
@ -1,20 +1,3 @@
|
|||
/*
|
||||
** Copyright 2022 Dolysis Consulting Limited
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** For changes see the git log
|
||||
*/
|
||||
package ipp
|
||||
|
||||
import (
|
||||
|
|
17
utils.go
17
utils.go
|
@ -1,20 +1,3 @@
|
|||
/*
|
||||
** Copyright 2022 Dolysis Consulting Limited
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** For changes see the git log
|
||||
*/
|
||||
package ipp
|
||||
|
||||
import (
|
||||
|
|
Loading…
Reference in New Issue