示例#1
0
        public static DescribeStreamProcessorResponse DescribeStreamProcessor(String streamProcessorName)
        {
            DescribeStreamProcessorResponse describeStreamProcessorResponse = null;

            try
            {
                AmazonRekognitionClient rekognitionClient;
                using (rekognitionClient = new AmazonRekognitionClient(MyAWSConfigs.KinesisRegion))
                {
                    describeStreamProcessorResponse = rekognitionClient
                                                      .DescribeStreamProcessor(new DescribeStreamProcessorRequest()
                    {
                        Name = streamProcessorName,
                    });
                }
            }
            catch (AmazonRekognitionException e)
            {
                Console.WriteLine("AmazonRekognitionException: " + e);
            }
            catch (Exception e)
            {
                Console.WriteLine("Error: " + e);
            }

            return(describeStreamProcessorResponse);
        }
示例#2
0
        public StreamProcessor DescribeStreamProcessor()
        {
            DescribeStreamProcessorResponse describeStreamProcessorResult = rekognitionClient
                                                                            .DescribeStreamProcessor(new DescribeStreamProcessorRequest()
            {
                Name = streamProcessorName,
            });

            StreamProcessor sp = new StreamProcessor()
            {
                Name   = describeStreamProcessorResult.Name,
                Status = describeStreamProcessorResult.Status,
            };

            return(sp);
        }